README.md 2.47 KB
Newer Older
1
2
3
4
5
6
<!--
SPDX-FileCopyrightText: 2020 Helmholtz Centre Potsdam - GFZ German Research Centre for Geosciences, Germany (https://www.gfz-potsdam.de/)

SPDX-License-Identifier: CC0-1.0
-->

Maximilian Schanner's avatar
Maximilian Schanner committed
7
# pymagglobal
Maximilian Schanner's avatar
Maximilian Schanner committed
8

9
10
11
**python interface for global geomagnetic field models**

[[_TOC_]]
Maximilian Schanner's avatar
Maximilian Schanner committed
12

13
14
`pymagglobal` serves the purpose of replacing some Fortran scripts, which are used in the geomagnetism community to evaluate global field models. It can be applied to all cubic-spline based geomagnetic field models stored in the same file format as gufm1 or the CALSxk model series. However, care has to be taken that two header lines of the model files are formatted correctly and the list of spline knot point epochs starts only in line 3. The first header line has to contain start and end epoch of the model as the first two numbers, any further information in that line is ignored. The second header line has to start with three integers, which are the maximum spherical harmonic degree, a dummy that actually is not used, and the number of splines.  
By default, `pymagglobal` includes several models. Use
Maximilian Schanner's avatar
Maximilian Schanner committed
15
16
17
```console
$ pymagglobal --list-models
```
18
to get a list of these default models or go to [pymagglobal/dat](https://gitext.gfz-potsdam.de/arthus/pymagglobal/-/tree/master/pymagglobal/dat) for further information. Using
Maximilian Schanner's avatar
Maximilian Schanner committed
19
```console
20
$ pymagglobal ... <path/to/your_model>
Maximilian Schanner's avatar
Maximilian Schanner committed
21
```
22
you can use `pymagglobal` to evaluate your own models, if they come in a similar format. `<path/to/your_model>` specifies the path to your model and is given instead of the name of an included model. You can download additional models [here](ftp://ftp.gfz-potsdam.de/home/mag/arthus/pymagglobal_models/) and use them as above.
Maximilian Schanner's avatar
Maximilian Schanner committed
23

24
Once installed, `pymagglobal` can be imported and its routines used to access the models from inside your own python code.
Maximilian Schanner's avatar
Maximilian Schanner committed
25

26
## License
Maximilian Schanner's avatar
Maximilian Schanner committed
27

28
Copyright © 2020 Helmholtz Centre Potsdam - GFZ German Research Centre for Geosciences, Germany (https://www.gfz-potsdam.de/)
Maximilian Schanner's avatar
Maximilian Schanner committed
29

30
31
32
33
34
This work is licensed under the following license(s):
* Insignificant files are licensed under [CC0-1.0](LICENSES/CC0-1.0.txt)
* Software files are licensed under [GPL-3.0-or-later](LICENSES/GPL-3.0-or-later.txt)
* Data files are licensed under [GPL-3.0-or-later](LICENSES/GPL-3.0-or-later.txt)
* Everything else is licensed under [GPL-3.0-or-later](LICENSES/GPL-3.0-or-later.txt)
Maximilian Schanner's avatar
Maximilian Schanner committed
35

36
Please see the individual files for more accurate information.
Maximilian Schanner's avatar
Maximilian Schanner committed
37

38
> **Hint:** We provided the copyright and license information in accordance to the [REUSE Specification 3.0](https://reuse.software/spec/).