From 77f03e8814315486bd2db5de484e2ad1c8b3bc96 Mon Sep 17 00:00:00 2001 From: Paweł Redman Date: Fri, 24 Jul 2020 18:28:14 +0200 Subject: Use the constant illuminant by default. --- demo.py | 2 +- otsu2018.py | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/demo.py b/demo.py index dbaa77d..eb02202 100644 --- a/demo.py +++ b/demo.py @@ -39,7 +39,7 @@ if __name__ == '__main__': plt.plot(sd.wavelengths, sd.values, label='Original') - XYZ = sd_to_XYZ(sd, illuminant=ILLUMINANT_SDS['D65']) / 100 + XYZ = sd_to_XYZ(sd) / 100 recovered_sd = clustering.reconstruct(XYZ) plt.plot(recovered_sd.wavelengths, recovered_sd.values, label='Recovered') diff --git a/otsu2018.py b/otsu2018.py index 88ab261..b99e563 100644 --- a/otsu2018.py +++ b/otsu2018.py @@ -4,7 +4,7 @@ import tqdm import time from colour import (SpectralDistribution, STANDARD_OBSERVER_CMFS, - ILLUMINANT_SDS, sd_to_XYZ, XYZ_to_xy) + sd_ones, sd_to_XYZ, XYZ_to_xy) from colour.plotting import plot_chromaticity_diagram_CIE1931 @@ -450,7 +450,7 @@ class Clustering: sds, shape, cmfs=STANDARD_OBSERVER_CMFS['CIE 1931 2 Degree Standard Observer'], - illuminant=ILLUMINANT_SDS['D65']): + illuminant=sd_ones()): """ Parameters ---------- -- cgit