[plotter] add the possibility to set rcParams in the conf file
This commit is contained in:
+3
-1
@@ -10,6 +10,8 @@ plot : # Plot parameters
|
|||||||
tight_layout : False # Wheter to apply tight_layout
|
tight_layout : False # Wheter to apply tight_layout
|
||||||
time_fmt : "time = {:.3g} {}" # Time format string, 1st field is time and 2nd is unit
|
time_fmt : "time = {:.3g} {}" # Time format string, 1st field is time and 2nd is unit
|
||||||
|
|
||||||
|
rcParams: # Anything there will be passed to matplotlib's rcParams
|
||||||
|
|
||||||
disk: # Disk speficic parameters
|
disk: # Disk speficic parameters
|
||||||
enable : False # Enable specific disk analysis
|
enable : False # Enable specific disk analysis
|
||||||
center : [0.5, 0.5, 0.5] # Position of the center of the disk (in fraction of lbox)
|
center : [0.5, 0.5, 0.5] # Position of the center of the disk (in fraction of lbox)
|
||||||
@@ -51,7 +53,7 @@ pymses: # Parameters for Pymses reader
|
|||||||
# Processing options
|
# Processing options
|
||||||
levelmax : 20 # Maximal AMR level visited when looking levels
|
levelmax : 20 # Maximal AMR level visited when looking levels
|
||||||
fft : False # Quick and dirty rendering using FFT
|
fft : False # Quick and dirty rendering using FFT
|
||||||
verbose : False # Let pymses write on standart output
|
verbose : True # Let pymses write on standart output
|
||||||
multiprocessing : True # Whether to use multiprocessing
|
multiprocessing : True # Whether to use multiprocessing
|
||||||
|
|
||||||
# Camera settings
|
# Camera settings
|
||||||
|
|||||||
+6
-1
@@ -173,9 +173,14 @@ class Plotter(Aggregator, BaseProcessor):
|
|||||||
# Define rules
|
# Define rules
|
||||||
self.def_rules()
|
self.def_rules()
|
||||||
|
|
||||||
# generate astrophysix's simulations object
|
# Load rcParams
|
||||||
|
if self.params.rcParams is not None:
|
||||||
|
plt.rcParams.update(params.rcParams)
|
||||||
|
|
||||||
|
# Generate astrophysix's simulations object
|
||||||
self.gen_simus()
|
self.gen_simus()
|
||||||
|
|
||||||
|
# Initialize pointers
|
||||||
self.current_processor = None
|
self.current_processor = None
|
||||||
|
|
||||||
def gen_simus(self):
|
def gen_simus(self):
|
||||||
|
|||||||
Reference in New Issue
Block a user