Closed wjlei1990 closed 8 years ago
Heyhey,
within ASDF it is uniform - QuakeML uses sane metric SI units and one cannot specify other units. When saving to or reading from ASDF one just needs to be aware of the units and convert if necessary.
The CMTSOLUTIONS files use km for the depth and dyne * cm for the moment tensor components which I always assumed are a relic from another time.
So yea - nothing to change in ASDF - one just has to be careful when converting.
Cheers
Lion
OK, I will check the writer and fix it as I think I don't convert to SI and leave SPECFEM3D units in the QuakeML.
OK. We will fix it at our side.
@jas11 Give me some time to think about how to do it in a clean way. Our calculation is heavily based on CMT files.
If you read the NDK or CMTSOLUTIONS files with ObsPy it will take care of all conversion issues - thus just adding them to ASDF with pyasdf should work without having to do anything. You only have to be careful on the side of SPECFEM.
Might also be important for the source inversion workflow.
I just checked obspy and found it supports CMTSOLUTION files now. Cool :)
I can now start using obspy instead of my own code.
If there is anything ObsPy does not read - please let me know. We want it all ;-)
Hi @krischer @jas11
I think we now need to make the unit in asdf file uniform.
Two things I have noticed in quakeml:
1) depth unit is meter in standard quakeml file but in CMTSOLUTION file(and specfem3d_globe) is km(kilometer) 2) For moment tensor, I think CMTSOLUTION(specfem3d_globe) is dyne/m(or something) but in standarnd quakeml file it is N/m.
By "standard quakeml" I mean the quakeml you gave me(convert from NDK file), Lion.
So do we need to keep the unit same or we add another attribute in quakeml to specify the unit?