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

Performance issues during reading mass-balance data caused by reading elevation bands #26

Open
yweidmann opened this issue Aug 3, 2018 · 1 comment
Assignees
Labels
enhancement New feature or request

Comments

@yweidmann
Copy link
Contributor

During reading the data of mass-balance readings, all connected elevation-bands are read as well and added to the according mass-balance object.
Some glaciers (e.g. Clariden) have a lot of mass-balance readings and elevation-bands.

The performance of the process has to be improved. Possible approaches:

  • Good design of the database indexes (foreign keys and primary keys of the elevation bands). This would be the best approach. Has to be tested first.
  • Lazy loading (only loading elevation bands if needed)
  • Additional parameter (telling the DataReader if elevation-bands have to be read as well)
@yweidmann yweidmann added the enhancement New feature or request label Aug 3, 2018
@yweidmann
Copy link
Contributor Author

The table mass_balance.elevation_distribution didn't had an index on the foreign key
Adding the index
INDEX "IXFK_elevation_distribution_mass_balance" ON mass_balance.elevation_distribution (fk_mass_balance ASC);
increased the performance of 1/3. But still not enough.

Further analysis in the Python code and query planning on the database needed. Currently only 25 transaction per second during the query for the UnitTest.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants