Issue #1317: Cannot set background color after changing color map (yt_analysis/yt)
New issue 1317: Cannot set background color after changing color map https://bitbucket.org/yt_analysis/yt/issues/1317/cannot-set-background-color... Hsi-Yu Schive: The following scripts fails. ``` #!python import yt ds = yt.load( "enzo/IsolatedGalaxy/galaxy0030/galaxy0030" ) sz = yt.SlicePlot( ds, 'z', 'density', center='c' ) sz.set_cmap( 'density', 'afmhot' ) sz.set_background_color( 'density' ) sz.save() ``` Error messages: ``` #!python File "demo.py", line 5, in <module> sz.set_background_color( 'density' ) File "/projects/ncsa/grav/hyschive/yt/yt.ori/yt/visualization/plot_container.py", line 69, in newfunc rv = f(*args, **kwargs) File "/projects/ncsa/grav/hyschive/yt/yt.ori/yt/visualization/plot_container.py", line 317, in set_background_color cmap = yt_colormaps[cmap] KeyError: 'afmhot' ``` Note that setting background color explicitly works. For example, ``` #!python sz.set_background_color( 'density', color='black' ) ```
participants (1)
-
Hsi-Yu Schive