Retrieval Settings
A module for handling the options for retrieving data for a shot, passed in the retrieval_settings
parameter of get_shots_data
.
disruption_py.settings.retrieval_settings ¤
This module defines the RetrievalSettings class, which is used to configure settings for retrieving data for a single shot.
InterpolationMethod ¤
Bases: Enum
Enum for specifying interpolation methods.
Source code in disruption_py/settings/retrieval_settings.py
32 33 34 35 36 37 38 39 40 41 42 |
|
RetrievalSettings
dataclass
¤
Settings for retrieving data for a single shot.
ATTRIBUTE | DESCRIPTION |
---|---|
cache_setting |
Cache setting to prefill data (default is None). Can pass any CacheSettingType that resolves to a CacheSetting. See CacheSetting for more details. Set to None if no data should be prefilled.
TYPE:
|
efit_nickname_setting |
Nickname setting for retrieving efit tree data (default is "disruption").
TYPE:
|
run_methods |
List of physics methods to run (default is an empty list). Named methods
will be run when retrieving data from MDSplus for the shot. Named methods
must have the physics_method decorator and either be passed in the
TYPE:
|
run_tags |
List of method tags to run (default is ["all"]). Methods used for retrieving
data from MDSplus can be tagged with the physics_method decorator and can
either be passed in the
TYPE:
|
run_columns |
List of columns to retrieve (default is an empty list). All methods with
the physics_method decorator referenced as containing an included column
will be run and all columns returned by those methods will be used. Methods
can either be passed in the
TYPE:
|
only_requested_columns |
Whether to only include requested columns in the result (default is False).
TYPE:
|
custom_physics_methods |
List of custom physics methods (default is an empty list). The Methods are collected and run when retrieving data from MDSplus if the method is included through either the run_methods, run_tags, run_columns setting.
TYPE:
|
time_setting |
Time setting for the shot (default is "disruption_warning"). The retrieved
data will be interpolated to this timebase. Can pass any
TYPE:
|
domain_setting |
Domain setting for the timebase (default is "full"). Either "full", "flattop",
or "rampup_and_flattop". Can pass any
TYPE:
|
use_cache_setting_timebase |
If True, use timebase from cache if available (default is False).
TYPE:
|
interpolation_method |
Interpolation method to be used (default is "linear"). CURRENTLY UNIMPLEMENTED.
TYPE:
|
Source code in disruption_py/settings/retrieval_settings.py
45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 |
|
__post_init__ ¤
__post_init__()
Resolve settings after initialization.
Source code in disruption_py/settings/retrieval_settings.py
115 116 117 |
|
from_dict
classmethod
¤
from_dict(prop_dict, tokamak: Tokamak)
Create a RetrievalSettings object from a dictionary.
PARAMETER | DESCRIPTION |
---|---|
prop_dict |
Dictionary containing properties for RetrievalSettings.
TYPE:
|
tokamak |
Tokamak for which to create settings.
TYPE:
|
RETURNS | DESCRIPTION |
---|---|
RetrievalSettings
|
A configured RetrievalSettings object. |
Source code in disruption_py/settings/retrieval_settings.py
119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 |
|
default_tags ¤
default_tags()
Return the default tag 'all'.
Source code in disruption_py/settings/retrieval_settings.py
27 28 29 |
|