Detect ground-motion types automatically
Ground-motion types are hard-coded into the program. A variable named gmDict
includes the column number of the ground-motion types in the GMF as its values and the ground-motion types as its keys.
For example, the ground-motion field for Attica has the format of lon,lat,PGA,SA(0.3),SA(0.6),SA(1)
Thus gmDict = {"PGA": 2, "SA(0.3)": 3, "SA(0.6)": 4, "SA(1)": 5}
But the program should automatically create gmDict
, because it will not remain the same for all ground-motion fields in the future.