Skip to content

Commit 22fa563

Browse files
authored
Update README.md
1 parent e82c632 commit 22fa563

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

README.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,8 +69,11 @@ In this task the goal is to reduce the storage requirement of an image with widt
6969
1. Open the file `src/ex2_image_compression.py`. The image is loaded in the `main` function using the `load_image` function. Inspect the `input_img` variable and print the information about its dimensions.
7070

7171
Implement the `compress_colorspace` function using the k-means algorithm:
72+
7273
2. Reshape the input image into $(w\cdot h, 3)$ to perform clustering on colors.
74+
7375
3. Use `MiniBatchKMeans` to cluster the image into $k$ clusters.
76+
7477
4. Return a compressed image where the number of unique colors where reduced from $256^3$ to $k$ via k-means clustering. The compressed image must have the same shape as the original one.
7578

7679
5. Use `compress_colorspace` in your `main` function to compress the image for $k \in \{2,8,64,256\}$ and plot the result using imshow. Set the corresponding value of $k$ as title for each result.

0 commit comments

Comments
 (0)