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

Error in merge_preeq_and_sim_pars_condition #433

Closed
LeonardSchmiester opened this issue May 1, 2020 · 1 comment
Closed

Error in merge_preeq_and_sim_pars_condition #433

LeonardSchmiester opened this issue May 1, 2020 · 1 comment
Assignees

Comments

@LeonardSchmiester
Copy link
Collaborator

par_sim / par_preeq in merge_preeq_and_sim_pars_condition can be strings in some cases leading to the error:

Traceback (most recent call last):
  File "/mnt/generate_h5_jerry.py", line 15, in <module>
    h5gen.generate_file(hdf5_file_name)
  File "/root/parPE/python/parpe/hdf5_pe_input.py", line 121, in generate_file
    self._generate_simulation_to_optimization_parameter_mapping()
  File "/root/parPE/python/parpe/hdf5_pe_input.py", line 424, in _generate_simulation_to_optimization_parameter_mapping
    condition_idx)
  File "/root/parPE/build/venv/lib/python3.7/site-packages/petab/parameter_mapping.py", line 513, in merge_preeq_and_sim_pars_condition
    and not (np.isnan(par_sim) and np.isnan(par_preeq)):
TypeError: ufunc 'isnan' not supported for the input types, and the inputs could not be safely coerced to any supported types according to the casting rule ''safe''

Should be fixable by replacing np.isnan with core.is_empty I think.

@yannikschaelte
Copy link
Member

agreed

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

No branches or pull requests

2 participants