[skip ci] better logic
This commit is contained in:
parent
4dae3643c9
commit
e33895dd35
|
@ -457,7 +457,7 @@ class Symmetry:
|
||||||
rgb = (theComponents/np.linalg.norm(theComponents,axis=-1,keepdims=True))**0.5 # smoothen color ramps
|
rgb = (theComponents/np.linalg.norm(theComponents,axis=-1,keepdims=True))**0.5 # smoothen color ramps
|
||||||
rgb = np.minimum(1.,rgb) # limit to maximum intensity
|
rgb = np.minimum(1.,rgb) # limit to maximum intensity
|
||||||
rgb /= np.max(rgb,axis=-1,keepdims=True) # normalize to (HS)V = 1
|
rgb /= np.max(rgb,axis=-1,keepdims=True) # normalize to (HS)V = 1
|
||||||
rgb[~np.broadcast_to(in_SST.reshape(vector[...,0].shape+(1,)),vector.shape)] = 0.0
|
rgb[np.broadcast_to(~in_SST.reshape(vector[...,0].shape+(1,)),vector.shape)] = 0.0
|
||||||
return (in_SST,rgb)
|
return (in_SST,rgb)
|
||||||
else:
|
else:
|
||||||
return in_SST
|
return in_SST
|
||||||
|
|
Loading…
Reference in New Issue