@@ -81,7 +81,13 class AmdaProvider(PyDataProvider): | |||
|
81 | 81 | |
|
82 | 82 | products = [] |
|
83 | 83 | for key, parameter in parameters.items(): |
|
84 | path = f"/AMDA/{parameter['mission']}/{parameter.get('observatory','')}/{parameter['instrument']}/{parameter['dataset']}/{parameter['name']}" | |
|
84 | mission_name = amda.mission[parameter['mission']]['name'] | |
|
85 | observatory_name = parameter.get('observatory','') | |
|
86 | if observatory_name != '': | |
|
87 | observatory_name = amda.observatory[observatory_name]['name'] | |
|
88 | instrument_name = amda.instrument[parameter['instrument']]['name'] | |
|
89 | dataset_name = amda.dataset[parameter['dataset']]['name'] | |
|
90 | path = f"/AMDA/{mission_name}/{observatory_name}/{instrument_name}/{dataset_name}/{parameter['name']}" | |
|
85 | 91 | components = [component['name'] for component in parameter.get('components',[])] |
|
86 | 92 | metadata = {key: item for key, item in parameter.items() if key is not 'components'} |
|
87 | 93 | n_components = parameter.get('size', 0) |
@@ -95,8 +101,9 class AmdaProvider(PyDataProvider): | |||
|
95 | 101 | metadata["type"] = "scalar" |
|
96 | 102 | products.append(Product(path, components, metadata)) |
|
97 | 103 | self.register_products(products) |
|
98 | for mission in amda.mission: | |
|
99 | self.set_icon(f'/AMDA/{mission}','satellite') | |
|
104 | for _,mission in amda.mission.items(): | |
|
105 | if ('target' in mission) and (mission['xml:id'] != 'Ephemerides') and (mission['target'] != 'Earth'): | |
|
106 | self.set_icon(f'/AMDA/{mission["name"]}','satellite') | |
|
100 | 107 | |
|
101 | 108 | def get_data(self, metadata, start, stop): |
|
102 | 109 | ts_type = amda_make_scalar |
General Comments 0
You need to be logged in to leave comments.
Login now