mt-metadata 0.3.3__py2.py3-none-any.whl → 0.3.5__py2.py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of mt-metadata might be problematic. Click here for more details.

Files changed (41) hide show
  1. mt_metadata/__init__.py +12 -10
  2. mt_metadata/base/metadata.py +24 -13
  3. mt_metadata/data/transfer_functions/tf_zmm.zmm +1 -1
  4. mt_metadata/timeseries/channel.py +8 -3
  5. mt_metadata/timeseries/filters/__init__.py +2 -2
  6. mt_metadata/timeseries/filters/{channel_response_filter.py → channel_response.py} +62 -29
  7. mt_metadata/timeseries/filters/coefficient_filter.py +1 -3
  8. mt_metadata/timeseries/filters/filter_base.py +70 -37
  9. mt_metadata/timeseries/filters/filtered.py +32 -22
  10. mt_metadata/timeseries/filters/fir_filter.py +10 -11
  11. mt_metadata/timeseries/filters/frequency_response_table_filter.py +9 -8
  12. mt_metadata/timeseries/filters/helper_functions.py +112 -3
  13. mt_metadata/timeseries/filters/pole_zero_filter.py +9 -8
  14. mt_metadata/timeseries/filters/standards/filter_base.json +2 -2
  15. mt_metadata/timeseries/filters/time_delay_filter.py +9 -8
  16. mt_metadata/timeseries/stationxml/fdsn_tools.py +8 -7
  17. mt_metadata/timeseries/stationxml/xml_channel_mt_channel.py +1 -1
  18. mt_metadata/timeseries/stationxml/xml_inventory_mt_experiment.py +4 -1
  19. mt_metadata/timeseries/tools/from_many_mt_files.py +15 -3
  20. mt_metadata/transfer_functions/__init__.py +1 -1
  21. mt_metadata/transfer_functions/core.py +89 -49
  22. mt_metadata/transfer_functions/io/edi/edi.py +9 -5
  23. mt_metadata/transfer_functions/io/edi/metadata/define_measurement.py +7 -3
  24. mt_metadata/transfer_functions/io/emtfxml/emtfxml.py +1 -4
  25. mt_metadata/transfer_functions/io/jfiles/jfile.py +2 -1
  26. mt_metadata/transfer_functions/io/zfiles/zmm.py +108 -62
  27. mt_metadata/transfer_functions/io/zonge/zonge.py +2 -2
  28. mt_metadata/transfer_functions/processing/aurora/band.py +16 -0
  29. mt_metadata/transfer_functions/processing/aurora/channel_nomenclature.py +34 -31
  30. mt_metadata/transfer_functions/processing/aurora/processing.py +12 -5
  31. mt_metadata/transfer_functions/processing/aurora/stations.py +11 -2
  32. mt_metadata/transfer_functions/processing/fourier_coefficients/decimation.py +1 -1
  33. mt_metadata/transfer_functions/processing/fourier_coefficients/standards/decimation.json +1 -1
  34. mt_metadata/transfer_functions/processing/fourier_coefficients/standards/fc_channel.json +23 -1
  35. mt_metadata/transfer_functions/tf/transfer_function.py +93 -1
  36. {mt_metadata-0.3.3.dist-info → mt_metadata-0.3.5.dist-info}/METADATA +379 -379
  37. {mt_metadata-0.3.3.dist-info → mt_metadata-0.3.5.dist-info}/RECORD +41 -41
  38. {mt_metadata-0.3.3.dist-info → mt_metadata-0.3.5.dist-info}/WHEEL +1 -1
  39. {mt_metadata-0.3.3.dist-info → mt_metadata-0.3.5.dist-info}/AUTHORS.rst +0 -0
  40. {mt_metadata-0.3.3.dist-info → mt_metadata-0.3.5.dist-info}/LICENSE +0 -0
  41. {mt_metadata-0.3.3.dist-info → mt_metadata-0.3.5.dist-info}/top_level.txt +0 -0
@@ -1,379 +1,379 @@
1
- Metadata-Version: 2.1
2
- Name: mt-metadata
3
- Version: 0.3.3
4
- Summary: Metadata for magnetotelluric data
5
- Home-page: https://github.com/kujaku11/mt_metadata
6
- Author: Jared Peacock
7
- Author-email: jpeacock@usgs.gov
8
- License: MIT license
9
- Keywords: mt_metadata
10
- Classifier: Development Status :: 2 - Pre-Alpha
11
- Classifier: Intended Audience :: Developers
12
- Classifier: License :: OSI Approved :: MIT License
13
- Classifier: Natural Language :: English
14
- Classifier: Programming Language :: Python :: 3
15
- Classifier: Programming Language :: Python :: 3.7
16
- Classifier: Programming Language :: Python :: 3.8
17
- Classifier: Programming Language :: Python :: 3.9
18
- Classifier: Programming Language :: Python :: 3.10
19
- Classifier: Programming Language :: Python :: 3.11
20
- Requires-Python: >=3.7
21
- Description-Content-Type: text/markdown
22
- License-File: LICENSE
23
- License-File: AUTHORS.rst
24
- Requires-Dist: numpy
25
- Requires-Dist: pandas
26
- Requires-Dist: obspy
27
- Requires-Dist: matplotlib
28
- Requires-Dist: xarray
29
- Requires-Dist: loguru
30
-
31
- # mt_metadata version 0.3.3
32
- Standard MT metadata
33
-
34
- [![PyPi version](https://img.shields.io/pypi/v/mt_metadata.svg)](https://pypi.python.org/pypi/mt-metadata)
35
- [![Latest conda|conda-forge version](https://img.shields.io/conda/v/conda-forge/mt-metadata.svg)](https://anaconda.org/conda-forge/mt-metadata)
36
- [![codecov](https://codecov.io/gh/kujaku11/mt_metadata/branch/main/graph/badge.svg?token=1WYF0G1L3D)](https://codecov.io/gh/kujaku11/mt_metadata)
37
- ![example workflow name](https://github.com/kujaku11/mt_metadata/workflows/TestingInConda/badge.svg)
38
- [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
39
- [![DOI](https://zenodo.org/badge/324097765.svg)](https://zenodo.org/badge/latestdoi/324097765)
40
- [![Binder](https://mybinder.org/badge_logo.svg)](https://mybinder.org/v2/gh/kujaku11/mt_metadata/main)
41
-
42
- # Description
43
-
44
- MT Metadata is a project led by [IRIS-PASSCAL MT Software working group](https://www.iris.edu/hq/about_iris/governance/mt_soft>) and USGS to develop tools that standardize magnetotelluric metadata, well, at least create tools for standards that are generally accepted. This include the two main types of magnetotelluric data
45
-
46
- - **Time Series**
47
- - Structured as:
48
- - Experiment -> Survey -> Station -> Run -> Channel
49
- - Supports translation to/from **StationXML**
50
-
51
- - **Transfer Functions**
52
- - Supports (will support) to/from:
53
- - **EDI** (most common format)
54
- - **ZMM** (Egberts EMTF output)
55
- - **JFILE** (BIRRP output)
56
- - **EMTFXML** (Kelbert's format)
57
- - **AVG** (Zonge output)
58
-
59
- Most people will be using the transfer functions, but a lot of that metadata comes from the time series metadata. This module supports both and has tried to make them more or less seamless to reduce complication.
60
-
61
- * **Version**: 0.3.3
62
- * **Free software**: MIT license
63
- * **Documentation**: https://mt-metadata.readthedocs.io.
64
- * **Examples**: Click the `Binder` badge above and Jupyter Notebook examples are in **mt_metadata/examples/notebooks** and **docs/source/notebooks**
65
- * **Suggested Citation**: Peacock, J. R., Kappler, K., Ronan, T., Heagy, L., Kelbert, A., Frassetto, A. (2022) MTH5: An archive and exchangeable data format for magnetotelluric time series data, *Computers & Geoscience*, **162**, doi:10.1016/j.cageo.2022.105102
66
-
67
-
68
- # Installation
69
-
70
- ## From Source
71
-
72
- `git clone git://github.com/kujaku11/mt_metadata`
73
-
74
- `python setup.py install`
75
-
76
- You can add the flag `-e` if you want to change the code.
77
-
78
- ## PIP
79
- `pip install mt_metadata`
80
-
81
- ## Conda
82
-
83
- `conda install mt_metadata`
84
-
85
- # Standards
86
-
87
- Each metadata keyword has an associated standard that goes with it. These are stored internally in JSON file. The JSON files are read in when the package is loaded to initialize the standards. Each keyword is described by:
88
-
89
- - **type** - How the value should be represented based on very basic types
90
-
91
- - *string*
92
- - *number* (float or integer)
93
- - *boolean*
94
-
95
- - **required** - A boolean (True or False) denoting whether the metadata key word required to represent the data.
96
- - **style** - How the value should be represented within the type. For instance is the value a controlled string where there are only a few options, or is the value a controlled naming convention where only a 5 character alpha-numeric string is allowed. The styles are
97
-
98
- - *Alpha Numeric* a string with alphabetic and numberic characters
99
- - *Free Form* a free form string
100
- - *Controlled Vocabulary* only certain values are allowed according to **options**
101
- - *Date* a date and/or time string in ISO format
102
- - *Number* a float or integer
103
- - *Boolean* the value can only be True or False
104
-
105
- - **units** - Units of the value
106
- - **description** - Full description of what the metadata key is meant to convey.
107
- - **options** - Any options of a **Controlled Vocabulary** style.
108
- - **alias** - Any aliases that may represent the same metadata key.
109
- - **example** - An example value to inform the user.
110
-
111
- All input values are internally validated according to the definition providing a robust way to standardize metadata.
112
-
113
- Each metadata object is based on a Base class that has methods:
114
-
115
- - to/from_json
116
- - to/from_xml
117
- - to_from_dict
118
- - attribute_information
119
-
120
- And each object has a doc string that describes the standard:
121
-
122
-
123
- | **Metadata Key** | **Description** | **Example** |
124
- |----------------------------------------------|-----------------------------------------------|----------------|
125
- | **key** | description of what the key describes | example value |
126
- | | | |
127
- | Required: False | | |
128
- | | | |
129
- | Units: None | | |
130
- | | | |
131
- | Type: string | | |
132
- | | | |
133
- | Style: controlled vocabulary | | |
134
-
135
-
136
- The time series module is more mature than the transfer function module at the moment, and this is still a work in progress.
137
-
138
-
139
- # Example
140
-
141
- ```
142
- from mt_metadata import timeseries
143
- x = timeseries.Instrument()
144
-
145
- ```
146
- # Help
147
- ```
148
- help(x)
149
-
150
- +----------------------------------------------+-----------------------------------------------+----------------+
151
- | **Metadata Key** | **Description** | **Example** |
152
- +==============================================+===============================================+================+
153
- | **id** | instrument ID number can be serial number or | mt01 |
154
- | | a designated ID | |
155
- | Required: True | | |
156
- | | | |
157
- | Units: None | | |
158
- | | | |
159
- | Type: string | | |
160
- | | | |
161
- | Style: free form | | |
162
- +----------------------------------------------+-----------------------------------------------+----------------+
163
- | **manufacturer** | who manufactured the instrument | mt gurus |
164
- | | | |
165
- | Required: True | | |
166
- | | | |
167
- | Units: None | | |
168
- | | | |
169
- | Type: string | | |
170
- | | | |
171
- | Style: free form | | |
172
- +----------------------------------------------+-----------------------------------------------+----------------+
173
- | **type** | instrument type | broadband |
174
- | | | 32-bit |
175
- | Required: True | | |
176
- | | | |
177
- | Units: None | | |
178
- | | | |
179
- | Type: string | | |
180
- | | | |
181
- | Style: free form | | |
182
- +----------------------------------------------+-----------------------------------------------+----------------+
183
- | **model** | model version of the instrument | falcon5 |
184
- | | | |
185
- | Required: False | | |
186
- | | | |
187
- | Units: None | | |
188
- | | | |
189
- | Type: string | | |
190
- | | | |
191
- | Style: free form | | |
192
- +----------------------------------------------+-----------------------------------------------+----------------+
193
- ```
194
-
195
- ## Fill in metadata
196
- ```
197
- x.model = "falcon 5"
198
- x.type = "broadband 32-bit"
199
- x.manufacturer = "MT Gurus"
200
- x.id = "f176"
201
- ```
202
-
203
- ## to JSON
204
- ```
205
- print(x.to_json())
206
- {
207
- "instrument": {
208
- "id": "f176",
209
- "manufacturer": "MT Gurus",
210
- "model": "falcon 5",
211
- "type": "broadband 32-bit"
212
- }
213
- }
214
- ```
215
-
216
- ## to XML
217
- ```
218
- print(x.to_xml(string=True))
219
- <?xml version="1.0" ?>
220
- <instrument>
221
- <id>f176</id>
222
- <manufacturer>MT Gurus</manufacturer>
223
- <model>falcon 5</model>
224
- <type>broadband 32-bit</type>
225
- </instrument>
226
-
227
- ```
228
-
229
-
230
- Credits
231
- -------
232
-
233
- This project is in cooperation with the Incorporated Research Institutes of Seismology, the U.S. Geological Survey, and other collaborators. Facilities of the IRIS Consortium are supported by the National Science Foundation’s Seismological Facilities for the Advancement of Geoscience (SAGE) Award under Cooperative Support Agreement EAR-1851048. USGS is partially funded through the Community for Data Integration and IMAGe through the Minerals Resources Program.
234
-
235
-
236
- History
237
- =========
238
-
239
-
240
- 0.1.0 (2020-12-30)
241
- ------------------
242
-
243
- * First release on PyPI.
244
-
245
- 0.1.3 (2021-06-25)
246
- -------------------
247
-
248
- * Added time series filters
249
-
250
- - PoleZeroFilter
251
- - CoefficientFilter
252
- - FIRFilter
253
- - TimeDelayFilter
254
- - FrequencyAmplitudePhaseFilter
255
-
256
- * Added translations to/from StationXML
257
- * Updated tests
258
- * Fixed minor bugs
259
- * Updated documentation
260
-
261
- 0.1.5 (2021-11-13)
262
- -------------------
263
-
264
- * Bug fixes
265
- * Updated how units are handled
266
- * If survey.id is None set it to fdsn.network if available (mainly an IRIS DMC fix)
267
- * Updated translation of Experiment to StationXML
268
- * Updated tests
269
-
270
- 0.1.6 (2021-12-07)
271
- --------------------
272
-
273
- * Bug fixes (mainly in mt_metadata.timeseries.filters)
274
- * Updated tests
275
- * Channel codes are handled "better"
276
- * Updating translation between Experiment and StationXML
277
- * Updated how filters are plotted
278
- * Adding notebooks to documentation
279
-
280
- 0.1.7 (2022-01-10)
281
- --------------------
282
-
283
- * Updating how transfer functions are handled
284
- * Added readers and metadata standards for
285
- - EDI files
286
- - Z-files
287
- - J-Files
288
- - AVG file
289
- - EMTF XML files
290
- * Added tests for transfer functions
291
- * Updated mt_metadata.transfer_functions.core.TF
292
- * Added documentation on transfer functions
293
-
294
- 0.1.8 (2022-04-07)
295
- --------------------
296
-
297
- * Bug fixes (mainly in the transfer functions)
298
- * Combined timeseries and transfer_function metadata where similar, so now transfer_function metadata imports from timeseries when applicable. Reduces files and redundancy.
299
- * Updated documentation
300
-
301
- 0.2.0 (2022-09-10)
302
- ---------------------
303
-
304
- * minor bug fixes
305
- * update reading .AVG files
306
-
307
- 0.2.1 (2023-01-18)
308
- ---------------------
309
-
310
- * Update setup.py
311
- * updating reading emtfxml files
312
- * Fix issue 95
313
- * Add model error
314
- * Make sure filter names are unique
315
- * Fix Empty Z file
316
- * Add metadata
317
- * added test for multiple networks in stationxml
318
- * updating to make mth5 work with single metadata object in ChannelTS and RunTS
319
- * added test for null channel component
320
- * Mth5 patch129 fixes
321
- * Update edi.py
322
- * add a line to allow aux channel component to be empty
323
- * Update edi.py
324
- * Mth5 patch129 fixes
325
-
326
- 0.2.2 (2023-02-17)
327
- ---------------------
328
-
329
- * Fixed bug in Station.channels_recorded when a string is input
330
-
331
- 0.2.3 (2023-04-24)
332
- ---------------------
333
-
334
- * Add methods for t0/from transfer function file type
335
- * Update when an np.datetime64 is input
336
- * MTime update to handle nanosecond accuracy
337
- * MTime and pandas Timestamp cannot handle large future or past dates
338
- * Fix input time with `isoformat` attribute
339
- * updating if a timedelta is subtracted
340
- * Updates from main into fix_issue_133
341
- * Fix issue #133
342
- * Update EMTFXML ouptut format
343
- * Add FC Metadata
344
-
345
- 0.3.0 (2023-09-29)
346
- ---------------------
347
-
348
- * Fixing Bugs in https://github.com/kujaku11/mt_metadata/pull/138
349
- * adding a merge for TFs in https://github.com/kujaku11/mt_metadata/pull/136
350
- * Fix write EDI bugs in https://github.com/kujaku11/mt_metadata/pull/149
351
- * Use loguru instead of builtin logging in https://github.com/kujaku11/mt_metadata/pull/153
352
- * Loguru in https://github.com/kujaku11/mt_metadata/pull/154
353
- * Try to fix bug with filter assignment in https://github.com/kujaku11/mt_metadata/pull/155
354
- * Empower edi in https://github.com/kujaku11/mt_metadata/pull/158
355
- * TF survey metadata in https://github.com/kujaku11/mt_metadata/pull/159
356
- * added logic for if channel location values are None in https://github.com/kujaku11/mt_metadata/pull/160
357
- * Changes to support writing z-files with channel_nomenclature in https://github.com/kujaku11/mt_metadata/pull/161
358
- * Minor changes to support zfiles tests in https://github.com/kujaku11/mt_metadata/pull/163
359
- * Test aurora issue 295 in https://github.com/kujaku11/mt_metadata/pull/165
360
- * Fcs in https://github.com/kujaku11/mt_metadata/pull/142
361
- * Fcs in https://github.com/kujaku11/mt_metadata/pull/166
362
- * Update environment.yml in https://github.com/kujaku11/mt_metadata/pull/167
363
- * updating documentation in https://github.com/kujaku11/mt_metadata/pull/168
364
-
365
- 0.3.1 (2023-10-15)
366
- -----------------------
367
-
368
- * Minor bug fixes
369
-
370
- 0.3.2 (2023-11-08)
371
- -----------------------
372
-
373
- * remove restriction on Pandas < 2
374
- * minor bug fixes
375
-
376
- 0.3.3 (2023-11-08)
377
- -----------------------
378
-
379
- * update pandas.append to concat
1
+ Metadata-Version: 2.1
2
+ Name: mt-metadata
3
+ Version: 0.3.5
4
+ Summary: Metadata for magnetotelluric data
5
+ Home-page: https://github.com/kujaku11/mt_metadata
6
+ Author: Jared Peacock
7
+ Author-email: jpeacock@usgs.gov
8
+ License: MIT license
9
+ Keywords: mt_metadata
10
+ Classifier: Development Status :: 2 - Pre-Alpha
11
+ Classifier: Intended Audience :: Developers
12
+ Classifier: License :: OSI Approved :: MIT License
13
+ Classifier: Natural Language :: English
14
+ Classifier: Programming Language :: Python :: 3
15
+ Classifier: Programming Language :: Python :: 3.7
16
+ Classifier: Programming Language :: Python :: 3.8
17
+ Classifier: Programming Language :: Python :: 3.9
18
+ Classifier: Programming Language :: Python :: 3.10
19
+ Classifier: Programming Language :: Python :: 3.11
20
+ Requires-Python: >=3.7
21
+ Description-Content-Type: text/markdown
22
+ License-File: LICENSE
23
+ License-File: AUTHORS.rst
24
+ Requires-Dist: numpy
25
+ Requires-Dist: pandas
26
+ Requires-Dist: obspy
27
+ Requires-Dist: matplotlib
28
+ Requires-Dist: xarray
29
+ Requires-Dist: loguru
30
+
31
+ # mt_metadata version 0.3.5
32
+ Standard MT metadata
33
+
34
+ [![PyPi version](https://img.shields.io/pypi/v/mt_metadata.svg)](https://pypi.python.org/pypi/mt-metadata)
35
+ [![Latest conda|conda-forge version](https://img.shields.io/conda/v/conda-forge/mt-metadata.svg)](https://anaconda.org/conda-forge/mt-metadata)
36
+ [![codecov](https://codecov.io/gh/kujaku11/mt_metadata/branch/main/graph/badge.svg?token=1WYF0G1L3D)](https://codecov.io/gh/kujaku11/mt_metadata)
37
+ ![example workflow name](https://github.com/kujaku11/mt_metadata/workflows/TestingInConda/badge.svg)
38
+ [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
39
+ [![DOI](https://zenodo.org/badge/324097765.svg)](https://zenodo.org/badge/latestdoi/324097765)
40
+ [![Binder](https://mybinder.org/badge_logo.svg)](https://mybinder.org/v2/gh/kujaku11/mt_metadata/main)
41
+
42
+ # Description
43
+
44
+ MT Metadata is a project led by [IRIS-PASSCAL MT Software working group](https://www.iris.edu/hq/about_iris/governance/mt_soft>) and USGS to develop tools that standardize magnetotelluric metadata, well, at least create tools for standards that are generally accepted. This include the two main types of magnetotelluric data
45
+
46
+ - **Time Series**
47
+ - Structured as:
48
+ - Experiment -> Survey -> Station -> Run -> Channel
49
+ - Supports translation to/from **StationXML**
50
+
51
+ - **Transfer Functions**
52
+ - Supports (will support) to/from:
53
+ - **EDI** (most common format)
54
+ - **ZMM** (Egberts EMTF output)
55
+ - **JFILE** (BIRRP output)
56
+ - **EMTFXML** (Kelbert's format)
57
+ - **AVG** (Zonge output)
58
+
59
+ Most people will be using the transfer functions, but a lot of that metadata comes from the time series metadata. This module supports both and has tried to make them more or less seamless to reduce complication.
60
+
61
+ * **Version**: 0.3.5
62
+ * **Free software**: MIT license
63
+ * **Documentation**: https://mt-metadata.readthedocs.io.
64
+ * **Examples**: Click the `Binder` badge above and Jupyter Notebook examples are in **mt_metadata/examples/notebooks** and **docs/source/notebooks**
65
+ * **Suggested Citation**: Peacock, J. R., Kappler, K., Ronan, T., Heagy, L., Kelbert, A., Frassetto, A. (2022) MTH5: An archive and exchangeable data format for magnetotelluric time series data, *Computers & Geoscience*, **162**, doi:10.1016/j.cageo.2022.105102
66
+
67
+
68
+ # Installation
69
+
70
+ ## From Source
71
+
72
+ `git clone https://github.com/kujaku11/mt_metadata.git`
73
+
74
+ `python setup.py install`
75
+
76
+ You can add the flag `-e` if you want to change the code.
77
+
78
+ ## PIP
79
+ `pip install mt_metadata`
80
+
81
+ ## Conda
82
+
83
+ `conda install mt_metadata`
84
+
85
+ # Standards
86
+
87
+ Each metadata keyword has an associated standard that goes with it. These are stored internally in JSON file. The JSON files are read in when the package is loaded to initialize the standards. Each keyword is described by:
88
+
89
+ - **type** - How the value should be represented based on very basic types
90
+
91
+ - *string*
92
+ - *number* (float or integer)
93
+ - *boolean*
94
+
95
+ - **required** - A boolean (True or False) denoting whether the metadata key word required to represent the data.
96
+ - **style** - How the value should be represented within the type. For instance is the value a controlled string where there are only a few options, or is the value a controlled naming convention where only a 5 character alpha-numeric string is allowed. The styles are
97
+
98
+ - *Alpha Numeric* a string with alphabetic and numberic characters
99
+ - *Free Form* a free form string
100
+ - *Controlled Vocabulary* only certain values are allowed according to **options**
101
+ - *Date* a date and/or time string in ISO format
102
+ - *Number* a float or integer
103
+ - *Boolean* the value can only be True or False
104
+
105
+ - **units** - Units of the value
106
+ - **description** - Full description of what the metadata key is meant to convey.
107
+ - **options** - Any options of a **Controlled Vocabulary** style.
108
+ - **alias** - Any aliases that may represent the same metadata key.
109
+ - **example** - An example value to inform the user.
110
+
111
+ All input values are internally validated according to the definition providing a robust way to standardize metadata.
112
+
113
+ Each metadata object is based on a Base class that has methods:
114
+
115
+ - to/from_json
116
+ - to/from_xml
117
+ - to_from_dict
118
+ - attribute_information
119
+
120
+ And each object has a doc string that describes the standard:
121
+
122
+
123
+ | **Metadata Key** | **Description** | **Example** |
124
+ |----------------------------------------------|-----------------------------------------------|----------------|
125
+ | **key** | description of what the key describes | example value |
126
+ | | | |
127
+ | Required: False | | |
128
+ | | | |
129
+ | Units: None | | |
130
+ | | | |
131
+ | Type: string | | |
132
+ | | | |
133
+ | Style: controlled vocabulary | | |
134
+
135
+
136
+ The time series module is more mature than the transfer function module at the moment, and this is still a work in progress.
137
+
138
+
139
+ # Example
140
+
141
+ ```
142
+ from mt_metadata import timeseries
143
+ x = timeseries.Instrument()
144
+
145
+ ```
146
+ # Help
147
+ ```
148
+ help(x)
149
+
150
+ +----------------------------------------------+-----------------------------------------------+----------------+
151
+ | **Metadata Key** | **Description** | **Example** |
152
+ +==============================================+===============================================+================+
153
+ | **id** | instrument ID number can be serial number or | mt01 |
154
+ | | a designated ID | |
155
+ | Required: True | | |
156
+ | | | |
157
+ | Units: None | | |
158
+ | | | |
159
+ | Type: string | | |
160
+ | | | |
161
+ | Style: free form | | |
162
+ +----------------------------------------------+-----------------------------------------------+----------------+
163
+ | **manufacturer** | who manufactured the instrument | mt gurus |
164
+ | | | |
165
+ | Required: True | | |
166
+ | | | |
167
+ | Units: None | | |
168
+ | | | |
169
+ | Type: string | | |
170
+ | | | |
171
+ | Style: free form | | |
172
+ +----------------------------------------------+-----------------------------------------------+----------------+
173
+ | **type** | instrument type | broadband |
174
+ | | | 32-bit |
175
+ | Required: True | | |
176
+ | | | |
177
+ | Units: None | | |
178
+ | | | |
179
+ | Type: string | | |
180
+ | | | |
181
+ | Style: free form | | |
182
+ +----------------------------------------------+-----------------------------------------------+----------------+
183
+ | **model** | model version of the instrument | falcon5 |
184
+ | | | |
185
+ | Required: False | | |
186
+ | | | |
187
+ | Units: None | | |
188
+ | | | |
189
+ | Type: string | | |
190
+ | | | |
191
+ | Style: free form | | |
192
+ +----------------------------------------------+-----------------------------------------------+----------------+
193
+ ```
194
+
195
+ ## Fill in metadata
196
+ ```
197
+ x.model = "falcon 5"
198
+ x.type = "broadband 32-bit"
199
+ x.manufacturer = "MT Gurus"
200
+ x.id = "f176"
201
+ ```
202
+
203
+ ## to JSON
204
+ ```
205
+ print(x.to_json())
206
+ {
207
+ "instrument": {
208
+ "id": "f176",
209
+ "manufacturer": "MT Gurus",
210
+ "model": "falcon 5",
211
+ "type": "broadband 32-bit"
212
+ }
213
+ }
214
+ ```
215
+
216
+ ## to XML
217
+ ```
218
+ print(x.to_xml(string=True))
219
+ <?xml version="1.0" ?>
220
+ <instrument>
221
+ <id>f176</id>
222
+ <manufacturer>MT Gurus</manufacturer>
223
+ <model>falcon 5</model>
224
+ <type>broadband 32-bit</type>
225
+ </instrument>
226
+
227
+ ```
228
+
229
+
230
+ Credits
231
+ -------
232
+
233
+ This project is in cooperation with the Incorporated Research Institutes of Seismology, the U.S. Geological Survey, and other collaborators. Facilities of the IRIS Consortium are supported by the National Science Foundation’s Seismological Facilities for the Advancement of Geoscience (SAGE) Award under Cooperative Support Agreement EAR-1851048. USGS is partially funded through the Community for Data Integration and IMAGe through the Minerals Resources Program.
234
+
235
+
236
+ History
237
+ =========
238
+
239
+
240
+ 0.1.0 (2020-12-30)
241
+ ------------------
242
+
243
+ * First release on PyPI.
244
+
245
+ 0.1.3 (2021-06-25)
246
+ -------------------
247
+
248
+ * Added time series filters
249
+
250
+ - PoleZeroFilter
251
+ - CoefficientFilter
252
+ - FIRFilter
253
+ - TimeDelayFilter
254
+ - FrequencyAmplitudePhaseFilter
255
+
256
+ * Added translations to/from StationXML
257
+ * Updated tests
258
+ * Fixed minor bugs
259
+ * Updated documentation
260
+
261
+ 0.1.5 (2021-11-13)
262
+ -------------------
263
+
264
+ * Bug fixes
265
+ * Updated how units are handled
266
+ * If survey.id is None set it to fdsn.network if available (mainly an IRIS DMC fix)
267
+ * Updated translation of Experiment to StationXML
268
+ * Updated tests
269
+
270
+ 0.1.6 (2021-12-07)
271
+ --------------------
272
+
273
+ * Bug fixes (mainly in mt_metadata.timeseries.filters)
274
+ * Updated tests
275
+ * Channel codes are handled "better"
276
+ * Updating translation between Experiment and StationXML
277
+ * Updated how filters are plotted
278
+ * Adding notebooks to documentation
279
+
280
+ 0.1.7 (2022-01-10)
281
+ --------------------
282
+
283
+ * Updating how transfer functions are handled
284
+ * Added readers and metadata standards for
285
+ - EDI files
286
+ - Z-files
287
+ - J-Files
288
+ - AVG file
289
+ - EMTF XML files
290
+ * Added tests for transfer functions
291
+ * Updated mt_metadata.transfer_functions.core.TF
292
+ * Added documentation on transfer functions
293
+
294
+ 0.1.8 (2022-04-07)
295
+ --------------------
296
+
297
+ * Bug fixes (mainly in the transfer functions)
298
+ * Combined timeseries and transfer_function metadata where similar, so now transfer_function metadata imports from timeseries when applicable. Reduces files and redundancy.
299
+ * Updated documentation
300
+
301
+ 0.2.0 (2022-09-10)
302
+ ---------------------
303
+
304
+ * minor bug fixes
305
+ * update reading .AVG files
306
+
307
+ 0.2.1 (2023-01-18)
308
+ ---------------------
309
+
310
+ * Update setup.py
311
+ * updating reading emtfxml files
312
+ * Fix issue 95
313
+ * Add model error
314
+ * Make sure filter names are unique
315
+ * Fix Empty Z file
316
+ * Add metadata
317
+ * added test for multiple networks in stationxml
318
+ * updating to make mth5 work with single metadata object in ChannelTS and RunTS
319
+ * added test for null channel component
320
+ * Mth5 patch129 fixes
321
+ * Update edi.py
322
+ * add a line to allow aux channel component to be empty
323
+ * Update edi.py
324
+ * Mth5 patch129 fixes
325
+
326
+ 0.2.2 (2023-02-17)
327
+ ---------------------
328
+
329
+ * Fixed bug in Station.channels_recorded when a string is input
330
+
331
+ 0.2.3 (2023-04-24)
332
+ ---------------------
333
+
334
+ * Add methods for t0/from transfer function file type
335
+ * Update when an np.datetime64 is input
336
+ * MTime update to handle nanosecond accuracy
337
+ * MTime and pandas Timestamp cannot handle large future or past dates
338
+ * Fix input time with `isoformat` attribute
339
+ * updating if a timedelta is subtracted
340
+ * Updates from main into fix_issue_133
341
+ * Fix issue #133
342
+ * Update EMTFXML ouptut format
343
+ * Add FC Metadata
344
+
345
+ 0.3.0 (2023-09-29)
346
+ ---------------------
347
+
348
+ * Fixing Bugs in https://github.com/kujaku11/mt_metadata/pull/138
349
+ * adding a merge for TFs in https://github.com/kujaku11/mt_metadata/pull/136
350
+ * Fix write EDI bugs in https://github.com/kujaku11/mt_metadata/pull/149
351
+ * Use loguru instead of builtin logging in https://github.com/kujaku11/mt_metadata/pull/153
352
+ * Loguru in https://github.com/kujaku11/mt_metadata/pull/154
353
+ * Try to fix bug with filter assignment in https://github.com/kujaku11/mt_metadata/pull/155
354
+ * Empower edi in https://github.com/kujaku11/mt_metadata/pull/158
355
+ * TF survey metadata in https://github.com/kujaku11/mt_metadata/pull/159
356
+ * added logic for if channel location values are None in https://github.com/kujaku11/mt_metadata/pull/160
357
+ * Changes to support writing z-files with channel_nomenclature in https://github.com/kujaku11/mt_metadata/pull/161
358
+ * Minor changes to support zfiles tests in https://github.com/kujaku11/mt_metadata/pull/163
359
+ * Test aurora issue 295 in https://github.com/kujaku11/mt_metadata/pull/165
360
+ * Fcs in https://github.com/kujaku11/mt_metadata/pull/142
361
+ * Fcs in https://github.com/kujaku11/mt_metadata/pull/166
362
+ * Update environment.yml in https://github.com/kujaku11/mt_metadata/pull/167
363
+ * updating documentation in https://github.com/kujaku11/mt_metadata/pull/168
364
+
365
+ 0.3.1 (2023-10-15)
366
+ -----------------------
367
+
368
+ * Minor bug fixes
369
+
370
+ 0.3.2 (2023-11-08)
371
+ -----------------------
372
+
373
+ * remove restriction on Pandas < 2
374
+ * minor bug fixes
375
+
376
+ 0.3.3 (2023-11-08)
377
+ -----------------------
378
+
379
+ * update pandas.append to concat