Blame view

CDF_spec.md 9.07 KB
ef9a8767   Nathanael Jourdane   Add the CDF specs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
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
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
# Formating CDF files for AMDADB

This specification follows the ISTP guidelines, see [the ISTP guide](https://spdf.gsfc.nasa.gov/istp_guide/).

---

## Global CDF attributes

See [the ISTP guidelines for global attributes](https://spdf.gsfc.nasa.gov/istp_guide/gattributes.html).

### Acknowledgement

Value of node `NumericalData/ResourceHeader/Acknowledgement` from SPASE file *NumericalData* corresponding to the granule.

> **Ex:**
>
>     NASA, Prof. Henri Reme, European Space Agency

### Data_type

Dataset name

> **Ex:**
>
>     PRP

### Data_version

    1

### Descriptor

Instrument name

> **Ex:**
>
>     CIS

### Discipline

- If target name is `sun` or `earth` : ***Space Physics***
- otherwise, look for node value of `NumericalData/ObservedRegion` from the *NumericalData* SPASE file corresponding to the granule:
	- if it's `Magnetosphere`: ***Space Physics>Magnetospheric Science***;
	- if it's `NearSurface`: ***Space Physics>Ionospheric Science***;
	- if it's `Heliosphere`: ***Space Physics>Interplanetary Studies***.

### Generated_by

    CDPP>Centre de Donnees de la Physique des Plasmas

### Generation_date

Value of node `NumericalData/ResourceHeader/ReleaseDate` from the *NumericalData* SPASE file corresponding to the granule, formated as *yyyymmdd*.

> **Ex:**
>
>     20151019

### HTTP_LINK

    http://amda.cdpp.eu

### Instrument_type

Value of node `Instrument/InstrumentType` from the *Instrument* SPASE file corresponding to the granule.

> **Ex:**
>
>     ElectrostaticAnalyser

### LINK_TEXT

Value of node `NumericalData/ResourceHeader/AlternateName` from the *NumericalData* SPASE file corresponding to the granule **+** ` data are available at `.

> **Ex:**
>
>     Cluster 1 Prime Parameter CIS data data are available at

### LINK_TITLE

    CDPP AMDA DATABASE

### Logical_file_id

Dataset name **+** `_` **+** `start_time` epn-core value, formated as `YYYYMMDDHHMMSS`.

Note: This is actually the file name without extension.

> **Ex**
>
>     CLUST1_CIS_PRP_19900302040000

### Logical_source

Dataset name

> **Ex:**
>
>     CLUST1_CIS_PRP

### Logical_source_description

Value of node `NumericalData/ResourceHeader/Description` from the *NumericalData* SPASE file corresponding to the granule.

> **Ex:**
>
>     This instrument (CIS: Cluster Ion Spectrometry) is capable of obtaining full 3D ion distributions with high time resolution (in one spacecraft spin) and mass-per-charge resolution. The experiment consists of [...]

### Mission_group

- Last element of the value of node `Observatory/ObservatoryGroupID` from the *Observatory* SPASE file corresponding to the granule.
- if the node doesn't exist: value of node `Observatory/ResourceName`.

> **Ex:**
>
>     Cluster

### MODS

    Extracted from NetCDF AMDA internal data.

### Parents

The NetCDF file name.

> **Ex**
>
>     CLUST1_CIS_PRP_19900302040000.nc

### PI_affiliation

Value of node `Person/OrganisationName` from the *Person* SPASE file corresponding to the granule.

> **Ex**
>
>     ESTEC, ESA

### PI_name

Value of node `NumericalData/Contact/PersonID` where `Role` node value is `PrincipalInvestigator`, from the *NumericalData* SPASE file corresponding to the granule.

> **Ex:**
>
>     Henri.Reme

### Project

A list with:

- `CDPP>Centre de Donnees de la Physique des Plasmas`
- the value of node `NumericalData/ProviderName`, from the *NumericalData* SPASE file corresponding to the granule.

> **Ex:**
>
>     - CDPP>Centre de Donnees de la Physique des Plasmas
>     - CSDS-CNES

### Rules_of_use

    System Use Policy

    Thank you for acknowledging the use of AMDA in publications with wording like "Data analysis was performed with the AMDA science analysis system provided by the Centre de Données de la Physique des Plasmas (CDPP) supported by CNRS, CNES, Observatoire de Paris and Université Paul Sabatier, Toulouse."

	Data use policy from originating <NAME> data center: <URL>

where :
- <NAME> is the value of node `NumericalData/ProviderName` from the SPASE file *NumericalData* corresponding to the granule, or CDPP if the value doesn't exist.
- and <URL> is kept from this dictionary (according to <NAME>).

- CDPP: http://amda.irap.omp.eu/help/licenceAction.do.html
- CDAWEB: http://spdf.gsfc.nasa.gov/new_users.html
- PDS: http://ppi.pds.nasa.gov/citations_policy.jsp
- MAPSKP: http://mapskp.cesr.fr/use_policy
- THEMIS: http://themis.ssl.berkeley.edu/roadrules.shtml
- MAVEN: http://lasp.colorado.edu/home/maven/files/2014/09/MAVEN_public-rules-of-the-road-v3.pdf
- CASSINI/RPWS/SKR: http://amda.irap.omp.eu/help/SKR.html
- VEXGRAZ: http://amda.irap.omp.eu/help/VEXGRAZ.html
- CAA: http://caa.estec.esa.int/caa/ror.xml
- CSA: http://www.cosmos.esa.int/web/csa/rules-of-the-road
- STEREO: http://amda.irap.omp.eu/help/STEREO.html
- CCMC: http://ccmc.gsfc.nasa.gov/PubPolicy.php


> **Ex:**
>
>     System Use Policy
>     
>     Thank you for acknowledging the use of AMDA in publications with wording like "Data analysis was performed with the AMDA science analysis system provided by the Centre de Données de la Physique des Plasmas (CDPP) supported by CNRS, CNES, Observatoire de Paris and Université Paul Sabatier, Toulouse."
>     
>     Data use policy from originating CDPP data center: http://amda.irap.omp.eu/help/licenceAction.do.html

### Software_version

Version of the NetCDF to CDF converter.

### Source_name

The mission name

> **Ex:**
>
>     clust1

### TEXT

The value of node `NumericalData/ResourceHeader/InformationURL/Name` **+** `, ` **+** the value of node `NumericalData/ResourceHeader/InformationURL/URL`, from the SPASE file *NumericalData* corresponding to the granule.

> **Ex:**
>
>     NSSDC Master Catalog listing for Cluster II Rumba Cluster Ion Spectrometry (CIS), http://nssdc.gsfc.nasa.gov/nmc/experimentDisplay.do?id=2000-045A-02

### Time_resolution

`time_sampling_step` value of epn-core, in seconds + ` seconds`.

> **Ex:**
>
>     3 seconds

### TITLE

The value of node `NumericalData/ResourceHeader/AlternateName`, from the SPASE file *NumericalData* corresponding to the granule.

> **Ex:**
>
>     Cluster 1 Prime Parameter CIS data

### PDS_Start_time

`time_min` value of epn-core, in ISO time.

> **Ex:**
>
>     2007-02-13T09:08:43Z

### PDS_Stop_time

`time_max` value of epn-core, in ISO time.

> **Ex:**
>
>     2007-02-14T09:08:43Z

### PDS_Observation_target

`target_name` value of epn-core. Use a list of values if necessary (split the `#` character).

> **Ex:**
>
>     Saturn

### Observation_type

Look for the child node in `NumericalData/Parameter` node, from the SPASE file *NumericalData* corresponding to the granule.

It is one of: `Field`, `Particules`, `Wave`, `Mixed`, `Support`.

> **Ex:**
>
>     Particle

### Other epn-core parameters

Add other epn-core parameters, with `VESPA_` prefix, only if:
- the value is not empty;
- this is not the same value as the other element of a tuple (ie min/max).

> **Ex:**
>
>     - VESPA_spase_measurement_type: EnergeticParticles
>     - VESPA_spatial_frame_type: cartesian

---

## Variable attributes (TBC)

See [the ISTP guidelines for variables](https://spdf.gsfc.nasa.gov/istp_guide/variables.html).

To create new variables with [spacepy.pycdf)(http://pythonhosted.org/SpacePy/pycdf.html), use [cdf.new()](http://pythonhosted.org/SpacePy/autosummary/spacepy.pycdf.CDF.html#spacepy.pycdf.CDF.new) and not `attr[]`.

To name variables, use the `NumericalData/Parameter/ParameterKey` parameter from the SPASE file.

c628de07   Nathanael Jourdane   Small changes on ...
283
284
285
286
287
288
### Metadata variable

## Variable attributes



ef9a8767   Nathanael Jourdane   Add the CDF specs
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
### `CATDESC`

type: CDF_CHAR

The value of node `NumericalData/Parameter/Description`.

> **Ex**
>
>     Flux density spectrogram measured on the RH polarized array.

### DEPEND_0

type : CDF_CHAR

    Epoch

### LABL_PTR_1

Note: Only if the node value of `NumericalData/Parameter/RenderingHints` is `time series` and the node `NumericalData/Parameter/Structure` exist.

Note 2: `LABL_PTR_1` and `DEPEND_1` can not are both presents.

**Step 1:** Get the labels, which are the nodes value of `NumericalData/Parameter/Structure/Element/Name`.

> **Ex (for skr151150000.nc.gz):**
>
>     - RH 100-400kHz
>     - LH 100-400kHz
>     - RH 10-1000kHz
>     - RH 10-1000kHz

**Step 2:** Create a new variable stored with these labels. Then `LABL_PTR_1` is the ID of this variable.

### DEPEND_1

Note: Only if the node value of `NumericalData/Parameter/RenderingHints` is `spectrogram`.

Note 2: `LABL_PTR_1` and `DEPEND_1` can not are both presents.

type : CDF_CHAR

From the file `<dataset_name>_info` from the dataset directory, look for `energy` or `frequency` variables value.

### DICT_KEY

type: CDF_CHAR

> **Ex:**
>
>     electric_field>power

### DISPLAY_TYPE

type: CDF_CHAR

> **Ex:**
>
>     time_series

### FIELDNAM

type: CDF_CHAR

> **Ex:**
>
>     RR

### FILLVAL

type: CDF_UINT1

> **Ex:**
>
>     255

### LABLAXIS

type: CDF_CHAR

> **Ex:**
>
>     RH flux density

### UNITS

type: CDF_CHAR

> **Ex:**
>
>     dB

### VALIDMIN

type: CDF_UINT1

> **Ex:**
>
>     0

### VALIDMAX

type: CDF_UINT1

> **Ex:**
>
>     255

### VAR_TYPE

type: CDF_CHAR

> **Ex:**
>
>     data

### SCALETYP

type: CDF_CHAR

> **Ex:**
>
>     lin

### SCALEMIN

type: CDF_UINT1

> **Ex:**
>
>     0

### SCALEMAX

> **Ex:**
>
>     255

### UCD