Commit 0fb012254e8de2f60a3ecfc41035da6169c7d2c7
1 parent
62372d94
Exists in
master
and in
9 other branches
float sampling
Showing
3 changed files
with
9 additions
and
8 deletions
Show diff stats
src/REMOTEDATA/CDAWEB.php
... | ... | @@ -14,10 +14,10 @@ class CDAWEB extends RemoteDataCenterClass |
14 | 14 | private $CDAWEB = array(), $masterCDF = array(); |
15 | 15 | |
16 | 16 | // https://cdaweb.gsfc.nasa.gov/WS/cdasr/1/dataviews/sp_phys/instrumentTypes |
17 | - private $validInstrumentTypes = [ "Activity%20Indices", "Electric%20Fields%20(space)","Gamma%20and%20X-Rays", | |
17 | + /*private $validInstrumentTypes = [ "Activity%20Indices", "Electric%20Fields%20(space)","Gamma%20and%20X-Rays", | |
18 | 18 | "Magnetic%20Fields%20(space)", "Particles%20(space)", "Plasma%20and%20Solar%20Wind", |
19 | - "Radio%20and%20Plasma%20Waves%20(space)" ]; | |
20 | - // private $validInstrumentTypes = [ "Magnetic%20Fields%20(space)" ]; | |
19 | + "Radio%20and%20Plasma%20Waves%20(space)" ]; */ | |
20 | + private $validInstrumentTypes = [ "Magnetic%20Fields%20(space)" ]; | |
21 | 21 | |
22 | 22 | // not used : $validInstrumentTypes = ["Ephemeris"]; |
23 | 23 | |
... | ... | @@ -420,8 +420,8 @@ class CDAWEB extends RemoteDataCenterClass |
420 | 420 | |
421 | 421 | $units = substr($cadence,-1); |
422 | 422 | |
423 | - $sampling = (int)$value*$scale[$units]; | |
424 | - | |
423 | + $sampling = floatval($value)*$scale[$units]; | |
424 | + | |
425 | 425 | return $sampling; |
426 | 426 | } |
427 | 427 | |
... | ... | @@ -566,7 +566,7 @@ class CDAWEB extends RemoteDataCenterClass |
566 | 566 | protected function convert2nc($file) |
567 | 567 | { |
568 | 568 | //TODO errors |
569 | - system("cdf2nc $file"); | |
569 | + system("cdfnew2nc $file"); | |
570 | 570 | $ncFile = str_replace(".cdf", ".nc", $file); |
571 | 571 | |
572 | 572 | if (!file_exists($ncFile)) return false; |
... | ... |
src/REMOTEDATA/CDAWebConfigClass.php
... | ... | @@ -16,7 +16,7 @@ class CDAWebConfigClass |
16 | 16 | public static $spaseRegistry = "https://heliophysicsdata.sci.gsfc.nasa.gov/queries/CDAWeb_SPASE.xql"; |
17 | 17 | // https://cdaweb.gsfc.nasa.gov/registry/hdp/NumericalData.xql : limited list |
18 | 18 | // http://spase-group.org/registry/explorer/ SMWG |
19 | - // Service to get SPACE description by SPASE ID (from $spaseRegistry) | |
19 | + // Service to get SPASE description by SPASE ID (from $spaseRegistry) | |
20 | 20 | public static $spaseResolver = "http://www.spase-group.org/registry/resolver?"; |
21 | 21 | public static $format = "CDF"; |
22 | 22 | } |
23 | 23 | \ No newline at end of file |
... | ... |
src/REMOTEDATA/makeProxy.php