Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Site/Rupture/Distance Context and attributes #18

Open
rizac opened this issue Dec 9, 2021 · 0 comments
Open

Site/Rupture/Distance Context and attributes #18

rizac opened this issue Dec 9, 2021 · 0 comments
Labels
discussion issue is actually meant to start a discussion question Further information is requested

Comments

@rizac
Copy link
Owner

rizac commented Dec 9, 2021

In the new ongoing ContextDB implementation, for each event /records tuple, we have our Ctx object with all Site/Rupture/Distance parameters. Because now we might have new parameters, I added a last part of code where I query the egsim db for all registered flatfile columns and relative Ctx attributes in order to add missing attributes to Ctx, in case.

The code works, perfect. But I noticed that in the legacy code the station coordinates were set as Ctx.lats, Cts.lons (plural). Hence, now we add (redundantly?) Ctx.lat and Ctx.lon, because these are the registered attribute names in eGSIM and OpenQuake.

The question here is not only what to do, but first of all how the code actually works (this is why is maybe better to have a zoom) because logically, it should work with lat and lon (no plural, as defined in OpenQuake). Probably there is some part in smtk where the conversion tooks place, in case we might see how to simplify the code, because this might be related to another topic I would like to discuss (i.e., stick to OpenQuake names whenever possible, there are in eGSIM some patches throughout the code for normalizing almost equal names, that might be avoided for clarity)

@rizac rizac added discussion issue is actually meant to start a discussion question Further information is requested labels Dec 9, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
discussion issue is actually meant to start a discussion question Further information is requested
Projects
None yet
Development

No branches or pull requests

1 participant