Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
G
geomag-algorithms
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
ghsc
National Geomagnetism Program
geomag-algorithms
Commits
01e1e4a7
Commit
01e1e4a7
authored
2 years ago
by
Erin (Josh) Rigler
Browse files
Options
Downloads
Plain Diff
Merge branch 'imfv122-parse-data-type' into 'master'
Parse data type in imfv122 files See merge request
!184
parents
f0d522b7
9408cf17
No related branches found
No related tags found
1 merge request
!184
Parse data type in imfv122 files
Pipeline
#148530
passed
2 years ago
Stage: init
Stage: test
Stage: integration
Stage: deploy
Changes
4
Pipelines
2
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
code.json
+2
-2
2 additions, 2 deletions
code.json
geomagio/imfv122/IMFV122Parser.py
+4
-0
4 additions, 0 deletions
geomagio/imfv122/IMFV122Parser.py
poetry.lock
+299
-296
299 additions, 296 deletions
poetry.lock
pyproject.toml
+1
-1
1 addition, 1 deletion
pyproject.toml
with
306 additions
and
299 deletions
code.json
+
2
−
2
View file @
01e1e4a7
...
...
@@ -3,7 +3,7 @@
"name"
:
"geomag-algorithms"
,
"organization"
:
"U.S. Geological Survey"
,
"description"
:
"Library for processing Geomagnetic timeseries data."
,
"version"
:
"1.5.
2
"
,
"version"
:
"1.5.
3
"
,
"status"
:
"Development"
,
"permissions"
:
{
...
...
@@ -34,7 +34,7 @@
},
"date"
:
{
"metadataLastUpdated"
:
"2022-0
5
-0
4
"
"metadataLastUpdated"
:
"2022-0
6
-0
1
"
}
}
]
This diff is collapsed.
Click to expand it.
geomagio/imfv122/IMFV122Parser.py
+
4
−
0
View file @
01e1e4a7
...
...
@@ -8,6 +8,9 @@ from obspy.core import UTCDateTime
EIGHTS
=
numpy
.
float64
(
"
888888
"
)
NINES
=
numpy
.
float64
(
"
999999
"
)
# valid data types and their IMFv122 single-character mapping
DATA_TYPES
=
{
"
R
"
:
"
Reported
"
,
"
A
"
:
"
Adjusted
"
,
"
D
"
:
"
Definitive
"
}
class
IMFV122Parser
(
object
):
"""
IMFV122 parser.
...
...
@@ -83,6 +86,7 @@ class IMFV122Parser(object):
self
.
metadata
[
"
geodetic_longitude
"
]
=
float
(
colalong
[
4
:])
/
10
self
.
metadata
[
"
station
"
]
=
observatory
self
.
metadata
[
"
gin
"
]
=
gin
self
.
metadata
[
"
data_type
"
]
=
DATA_TYPES
[
type
.
upper
()]
year
=
1900
+
int
(
date
[
-
2
:])
julday
=
int
(
doy
)
...
...
This diff is collapsed.
Click to expand it.
poetry.lock
+
299
−
296
View file @
01e1e4a7
This diff is collapsed.
Click to expand it.
pyproject.toml
+
1
−
1
View file @
01e1e4a7
...
...
@@ -17,7 +17,7 @@ packages = [
{include
=
"geomagio"
}
]
repository
=
"https://code.usgs.gov/ghsc/geomag/geomag-algorithms"
version
=
"1.5.
2
"
version
=
"1.5.
3
"
[tool.poetry.dependencies]
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment