Skip to content
Snippets Groups Projects
Commit f33412e8 authored by Colm Talbot's avatar Colm Talbot
Browse files

flake fix

parent ec6084e0
No related branches found
No related tags found
1 merge request!271Improve cosmology use
Pipeline #45506 passed
......@@ -47,7 +47,7 @@ def set_cosmology(cosmology=None):
elif isinstance(cosmology, cosmo.FLRW):
cosmology = cosmology
elif isinstance(cosmology, str):
cosmology = eval('cosmo.' + cosmology)
cosmology = cosmo.__dict__[cosmology]
elif isinstance(cosmology, dict):
if 'Ode0' in cosmology.keys():
if 'w0' in cosmology.keys():
......
......@@ -41,9 +41,9 @@ class UniformComovingVolume(FromFile):
if cosmology is None:
cosmology = COSMOLOGY[0]
elif isinstance(cosmology, str):
cosmology = eval('cosmo.' + cosmology)
cosmology = cosmo.__dict__[cosmology]
if isinstance(unit, str):
unit = eval('units.' + unit)
unit = units.__dict__[unit]
if minimum == 0:
z_min = 0
else:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment