mirror of
https://github.com/KrisKennaway/ii-pix.git
synced 2024-06-02 12:41:35 +00:00
Remove debugging prints
This commit is contained in:
parent
ed2082344a
commit
e53c085a91
|
@ -65,7 +65,6 @@ class ClusterPalette:
|
||||||
res[i, :] = dither_pyx.convert_cam16ucs_to_rgb12_iigs(
|
res[i, :] = dither_pyx.convert_cam16ucs_to_rgb12_iigs(
|
||||||
clusters.cluster_centers_[frequency_order][i].astype(
|
clusters.cluster_centers_[frequency_order][i].astype(
|
||||||
np.float32))
|
np.float32))
|
||||||
print(res)
|
|
||||||
return res
|
return res
|
||||||
|
|
||||||
def propose_palettes(self) -> Tuple[np.ndarray, np.ndarray, List[float]]:
|
def propose_palettes(self) -> Tuple[np.ndarray, np.ndarray, List[float]]:
|
||||||
|
|
|
@ -586,11 +586,11 @@ def k_means_with_fixed_centroids(
|
||||||
new_centroid_rgb12 = convert_cam16ucs_to_rgb12_iigs(new_centroid_cam)
|
new_centroid_rgb12 = convert_cam16ucs_to_rgb12_iigs(new_centroid_cam)
|
||||||
for i in range(3):
|
for i in range(3):
|
||||||
if centroids_rgb12[centroid_idx, i] != new_centroid_rgb12[i]:
|
if centroids_rgb12[centroid_idx, i] != new_centroid_rgb12[i]:
|
||||||
print(i, centroids_rgb12[centroid_idx, i], new_centroid_rgb12[i])
|
# print(i, centroids_rgb12[centroid_idx, i], new_centroid_rgb12[i])
|
||||||
centroids_rgb12[centroid_idx, i] = new_centroid_rgb12[i]
|
centroids_rgb12[centroid_idx, i] = new_centroid_rgb12[i]
|
||||||
centroid_moved = 1
|
centroid_moved = 1
|
||||||
|
|
||||||
print(iteration, centroid_movement, total_error, centroids_rgb12)
|
# print(iteration, centroid_movement, total_error, centroids_rgb12)
|
||||||
|
|
||||||
if centroid_movement < tolerance:
|
if centroid_movement < tolerance:
|
||||||
break
|
break
|
||||||
|
|
Loading…
Reference in New Issue
Block a user