New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
DM-36726: Update to new version of fgcm which fixes color map issue. #34
Conversation
Fix colormap setting in focal plane plots.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have a couple suggestions, but it's fine as is if you get rid of the unused variables.
@@ -471,11 +471,12 @@ def plotCCDMap(ax, deltaMapper, values, cbLabel, loHi=None): | |||
ax.scatter(deltaMapper['delta_ra'].ravel(), deltaMapper['delta_dec'].ravel(), | |||
s=0.1, | |||
c=zGrid.ravel(), | |||
vmin=lo, vmax=hi) | |||
vmin=lo, vmax=hi, | |||
cmap=cm) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You're not using cNorm
or scalarMap
from above anywhere. I suspect maybe cNorm
was supposed to be used here instead of setting vmin
and vmax
?
ax.set_aspect('equal') | ||
|
||
cb = None | ||
cb = plt.colorbar(CS3, ticks=np.linspace(lo, hi, 5), ax=ax) | ||
cb = plt.colorbar(CS3, ticks=np.linspace(lo, hi, 5), ax=ax, cmap=cm) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think you could use your scalarMap
from above here (plt.colorbar(scalarMap)
) , then not need to set anything else, but I'm not 100% sure what you're trying to do.
No description provided.