colour.recovery.RGB_to_msds_camera_sensitivities_Jiang2013#
- colour.recovery.RGB_to_msds_camera_sensitivities_Jiang2013(RGB: Domain1, illuminant: SpectralDistribution, reflectances: MultiSpectralDistributions, basis_functions: ArrayLike = BASIS_FUNCTIONS_DYER2017, shape: SpectralShape | None = None) MultiSpectralDistributions[source]#
Recover the camera RGB sensitivities for the specified camera RGB values using Jiang et al. (2013) method.
- Parameters:
RGB (Domain1) – Camera RGB values corresponding with
reflectances.illuminant (SpectralDistribution) – Illuminant spectral distribution used to produce the camera RGB values.
reflectances (MultiSpectralDistributions) – Reflectance spectral distributions used to produce the camera RGB values.
basis_functions (ArrayLike) – Basis functions for the method. The default is to use the built-in sRGB basis functions, i.e.,
colour.recovery.BASIS_FUNCTIONS_DYER2017.shape (SpectralShape | None) – Spectral shape of the recovered camera RGB sensitivities. The
illuminantandreflectanceswill be aligned to it if passed, otherwise, theilluminantshape is used.
- Returns:
Recovered camera RGB sensitivities.
- Return type:
colour.RGB_CameraSensitivities
Notes
Domain
Scale - Reference
Scale - 1
RGB1
1
Examples
>>> from colour.colorimetry import ( ... SDS_ILLUMINANTS, ... msds_to_XYZ, ... sds_and_msds_to_msds, ... ) >>> from colour.characterisation import ( ... MSDS_CAMERA_SENSITIVITIES, ... SDS_COLOURCHECKERS, ... ) >>> from colour.recovery import SPECTRAL_SHAPE_BASIS_FUNCTIONS_DYER2017 >>> illuminant = SDS_ILLUMINANTS["D65"] >>> sensitivities = MSDS_CAMERA_SENSITIVITIES["Nikon 5100 (NPL)"] >>> reflectances = [ ... sd.copy().align(SPECTRAL_SHAPE_BASIS_FUNCTIONS_DYER2017) ... for sd in SDS_COLOURCHECKERS["BabelColor Average"].values() ... ] >>> reflectances = sds_and_msds_to_msds(reflectances) >>> RGB = ( ... msds_to_XYZ( ... reflectances, ... method="Integration", ... cmfs=sensitivities, ... illuminant=illuminant, ... k=1, ... shape=SPECTRAL_SHAPE_BASIS_FUNCTIONS_DYER2017, ... ) ... / 100 ... ) >>> RGB_to_msds_camera_sensitivities_Jiang2013( ... RGB, ... illuminant, ... reflectances, ... BASIS_FUNCTIONS_DYER2017, ... SPECTRAL_SHAPE_BASIS_FUNCTIONS_DYER2017, ... ).values array([[ 7.04378461e-03, 9.21260449e-03, -7.64080878e-03], [-8.76715607e-03, 1.12726694e-02, 6.37434190e-03], [ 4.58126856e-02, 7.18000418e-02, 4.00001696e-01], [ 7.59391152e-02, 1.15620933e-01, 7.11521550e-01], [ 6.77685732e-02, 1.53406449e-01, 8.52668310e-01], [ 5.19341313e-02, 1.88575472e-01, 9.38957846e-01], [ 4.38070562e-02, 2.61086603e-01, 9.72130729e-01], [ 4.53453213e-02, 3.75440392e-01, 9.61450686e-01], [ 5.06945146e-02, 4.47658155e-01, 8.86481146e-01], [ 4.28378252e-02, 4.50713447e-01, 7.51770770e-01], [ 4.10520309e-02, 6.16577286e-01, 5.52730730e-01], [ 5.28436974e-02, 7.80199548e-01, 3.82269175e-01], [ 9.42655432e-02, 9.17674257e-01, 2.40354614e-01], [ 1.39544593e-01, 1.00000000e+00, 1.55374812e-01], [ 7.81438836e-02, 9.27720273e-01, 1.04409358e-01], [ 4.53805297e-02, 8.56701565e-01, 6.51222854e-02], [ 5.22164960e-02, 7.52322921e-01, 3.42954473e-02], [ 1.02816526e-01, 6.25809730e-01, 2.09495104e-02], [ 5.16941760e-01, 4.92746166e-01, 1.48524616e-02], [ 9.56397935e-01, 3.43364817e-01, 1.08983186e-02], [ 9.73494777e-01, 2.08587708e-01, 7.00494396e-03], [ 8.19461415e-01, 1.11784838e-01, 4.47180002e-03], [ 6.76174158e-01, 6.59071962e-02, 4.10135388e-03], [ 5.56804177e-01, 4.46268353e-02, 4.18528982e-03], [ 4.19601114e-01, 3.33671033e-02, 4.49165886e-03], [ 2.95578342e-01, 2.39487762e-02, 4.45932739e-03], [ 2.27050628e-01, 1.87787770e-02, 4.31697313e-03], [ 1.34118359e-01, 1.06954985e-02, 3.41192651e-03], [ 4.00195568e-02, 5.55512389e-03, 1.36794925e-03], [-4.32240535e-03, 2.49731193e-03, 3.80303275e-04], [-6.00395414e-03, 1.54678227e-03, 5.40394352e-04]])