Commit fd1829c318f4284d20723d894a967ba626def7d3

Authored by Goutte
1 parent 2fe06b17

Use the new AMDA API

Add Mercury Real Time
Add Venus Real Time
Showing 3 changed files with 25 additions and 21 deletions   Show diff stats
@@ -29,13 +29,21 @@ et prendre aussi @@ -29,13 +29,21 @@ et prendre aussi
29 29
30 ## Future ? 30 ## Future ?
31 31
32 -- [ ] Set the log level to _error_ in production (see `web/run.py`)  
33 -- [ ] Rework the images of Rosetta and Juno 32 +- [ ] Re-enable Earth
34 - [ ] Enable p67 33 - [ ] Enable p67
35 - [ ] Layer : Auroral Emissions 34 - [ ] Layer : Auroral Emissions
  35 +- [ ] Set the log level to _error_ in production (see `web/run.py`)
  36 +- [ ] Add a README to the download tarball (no tarball anymore)
  37 +- [ ] Rework the images of Rosetta and Juno
36 - [ ] Optimize data aggregation (numpy vectorization?) 38 - [ ] Optimize data aggregation (numpy vectorization?)
37 - [ ] IE compat, if you can (I can't) 39 - [ ] IE compat, if you can (I can't)
38 -- [ ] Add a README to the download tarball (no tarball anymore) 40 +
  41 +
  42 +## 1.5
  43 +
  44 +- [x] Use the new AMDA API
  45 +- [x] Add Mercury Real Time
  46 +- [x] Add Venus Real Time
39 47
40 48
41 ## 1.4 49 ## 1.4
@@ -44,7 +44,8 @@ authors: @@ -44,7 +44,8 @@ authors:
44 mail: vincent.genot@irap.omp.eu 44 mail: vincent.genot@irap.omp.eu
45 45
46 46
47 -amda: "http://cdpp.irap.omp.eu/BASE/DDService/getDataUrl.php?dataSet={dataSet}&StartTime={startTime}&StopTime={stopTime}" 47 +#amda: "http://cdpp.irap.omp.eu/BASE/DDService/getDataUrl.php?dataSet={dataSet}&StartTime={startTime}&StopTime={stopTime}"
  48 +amda: "http://amda.irap.omp.eu/DDService/getDataUrl.php?dataSet={dataSet}&StartTime={startTime}&StopTime={stopTime}"
48 49
49 50
50 # Data files are in data/catalog/ 51 # Data files are in data/catalog/
@@ -99,15 +100,6 @@ inputs: @@ -99,15 +100,6 @@ inputs:
99 name: "STEREO-B" 100 name: "STEREO-B"
100 desc: "The second of the STEREO (Solar Terrestrial Relations Observatory), a solar observation mission." 101 desc: "The second of the STEREO (Solar Terrestrial Relations Observatory), a solar observation mission."
101 102
102 -#Targets  
103 -#Earth earth_orb_all  
104 -#Jupiter jupiter_orb_all  
105 -#Mars mars_orb_all  
106 -#Mercury mercury_orb_all  
107 -#Neptune neptune_orb_all  
108 -#Venus venus_orb_all  
109 -#Uranus uranus_orb_all  
110 -#  
111 #Comets 103 #Comets
112 #67P p67_orb_all 104 #67P p67_orb_all
113 # 105 #
@@ -142,6 +134,7 @@ targets: @@ -142,6 +134,7 @@ targets:
142 models: 134 models:
143 l1: 135 l1:
144 - slug: 'tao_mercury_sw' 136 - slug: 'tao_mercury_sw'
  137 + - slug: 'tao_mercury_swrt'
145 sa: 138 sa:
146 - slug: 'tao_mercury_sw' 139 - slug: 'tao_mercury_sw'
147 sb: 140 sb:
@@ -160,6 +153,7 @@ targets: @@ -160,6 +153,7 @@ targets:
160 models: 153 models:
161 l1: 154 l1:
162 - slug: 'tao_venus_sw' 155 - slug: 'tao_venus_sw'
  156 + - slug: 'tao_venus_swrt'
163 sa: 157 sa:
164 - slug: 'tao_venus_sw' 158 - slug: 'tao_venus_sw'
165 sb: 159 sb:
@@ -514,7 +514,7 @@ def get_data_for_target(target_config, input_slug, @@ -514,7 +514,7 @@ def get_data_for_target(target_config, input_slug,
514 raise Exception("No variable '%s' found in NetCDF." % _keys[_key]) 514 raise Exception("No variable '%s' found in NetCDF." % _keys[_key])
515 return [None] * len(_nc.variables['Time']) # slow -- use numpy! 515 return [None] * len(_nc.variables['Time']) # slow -- use numpy!
516 516
517 - # Override these using the model configurationget_data_for_target 517 + # Override these using the model configuration in config.yml
518 default_nc_keys = { 518 default_nc_keys = {
519 'hee': 'HEE', 519 'hee': 'HEE',
520 'vtot': 'V', 520 'vtot': 'V',
@@ -646,13 +646,15 @@ def get_data_for_target(target_config, input_slug, @@ -646,13 +646,15 @@ def get_data_for_target(target_config, input_slug,
646 646
647 # Keep adding exceptions here until you can't or become mad 647 # Keep adding exceptions here until you can't or become mad
648 648
649 - # /!\ MUST be in the same order as PROPERTIES  
650 - all_data[dkey] = (  
651 - dtime.strftime("%Y-%m-%dT%H:%M:%S+00:00"),  
652 - vrad, vtan, vtot,  
653 - datum_b, datum_t, datum_p, datum_n, datum_a,  
654 - x_hee, y_hee  
655 - ) 649 + # First model has priority: ignore data from other models
  650 + if dkey not in all_data:
  651 + # /!\ MUST be in the same order as PROPERTIES
  652 + all_data[dkey] = (
  653 + dtime.strftime("%Y-%m-%dT%H:%M:%S+00:00"),
  654 + vrad, vtan, vtot,
  655 + datum_b, datum_t, datum_p, datum_n, datum_a,
  656 + x_hee, y_hee
  657 + )
656 cdf_handle.close() 658 cdf_handle.close()
657 659
658 return all_data 660 return all_data