Closed rkingsbury closed 1 year ago
Attention: 8 lines
in your changes are missing coverage. Please review.
Files | Coverage Δ | |
---|---|---|
src/pyEQL/__init__.py | 100.00% <100.00%> (ø) |
|
src/pyEQL/engines.py | 81.52% <100.00%> (ø) |
|
src/pyEQL/utils.py | 100.00% <100.00%> (ø) |
|
src/pyEQL/equilibrium.py | 50.00% <50.00%> (ø) |
|
src/pyEQL/solution.py | 83.12% <86.79%> (-0.28%) |
:arrow_down: |
:loudspeaker: Thoughts on this report? Let us know!.
Summary
Miscellaneous changes to improve pyEQL's speed. Reduces the time required for many common operations by 3x - 10x.
Major changes:
ureg.Quantity
by using magnitudes where feasibleQuantity(float, 'unit') instead of
Quantity('float unit') which is substantially fasterpyEQL.__init__
to speed up subsequent access bySolution
objectslru_cache
for solution propertiesResults (results of
%%timeit
(ms), before / after)Solution
: 301 / 84s.get_activity_coefficient('Na+')
: 27 / 14s.conductivity
: 143 / 44s.ionic_strength
: 5 / 0.5