gem / oq-engine

OpenQuake Engine: a software for Seismic Hazard and Risk Analysis
https://github.com/gem/oq-engine/#openquake-engine
GNU Affero General Public License v3.0
380 stars 273 forks source link

Small refactoring of get_rlzs_by_gsim #9752

Closed micheles closed 4 months ago

micheles commented 4 months ago

Save 5 GB of RAM in EUR:

# before
| calc_464, maxmem=181.4 GB  | time_sec | memory_mb | counts  |
|----------------------------+----------+-----------+---------|
| PreClassicalCalculator.run | 2_660    | 111_210   | 1       |
| total preclassical         | 1_591    | 175.5117  | 352     |
| importing inputs           | 1_251    | 84_957    | 1       |
| composite source model     | 1_249    | 84_935    | 1       |
| building full_lt           | 1_234    | 84_765    | 1       |

# after
| calc_465, maxmem=176.6 GB  | time_sec | memory_mb | counts  |
|----------------------------+----------+-----------+---------|
| PreClassicalCalculator.run | 2_659    | 106_655   | 1       |
| total preclassical         | 1_590    | 175.4844  | 352     |
| importing inputs           | 1_242    | 84_955    | 1       |
| composite source model     | 1_240    | 84_931    | 1       |
| building full_lt           | 1_226    | 84_767    | 1       |