gafusion / omas

Ordered Multidimensional Array Structure
http://gafusion.github.io/omas
MIT License
30 stars 14 forks source link

Errors In Machine Mapping for DIII-D #225

Closed torrinba closed 1 year ago

torrinba commented 1 year ago

Loading DIII-D data into the charge_exchange, core_profiles, and gas_injection ods produces errors when they are used.

The easiest way to observe this is to execute the following:

ods=ODS()
ods.load('d3d',178898)

This produces the errors:

charge_exchange ods:

Error in loading tree representation:
KeyError(0)

core_profiles ods:

Error with GUI representation of `['commandBox']['ods']['core_profiles']['time']`: OmasDynamicException('Error dynamic fetching of `core_profiles.time` for {\'machine\': \'d3d\', \'pulse\': 178898, \'options\': {}, \'branch\': \'\', \'user_machine_mappings\': None}: TypeError("magnetics_hardware() missing 1 required positional argument: \'pulse\'")')

gas_injection ods:

LookupError('Not a valid IMAS 3.37.0 location: gas_injection.pipe.0.valve\n                                                                    ^^^^^\nDid you mean: valve_indices, name, length, flow_rate, length_error_upper, ...')
orso82 commented 1 year ago

@bechtt as the error says, looks like magnetics_hardware() is called without passing the pulse argument? Seach

Concerning the gas_injection IDS, i believe there have been changes to the IMAS data structure between the time that the data mapping was done and now. Looking at the v3.37.0 it looks like valve has been moved outside of pipe (probably to allow different valves to use the same pipe), so the logic should be revised. image I don't have a gauge if this is a simple translation, or it needs more thought. This is work that @eldond had done. He might be able to help and advise. For the time being, if you are not using the gas_injection information, we could simply remove it from the list of supported DIII-D mappings.

torrinba commented 1 year ago

Addressed in #226