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

BMI and request of scalar variables #331

Closed
2 tasks done
verseve opened this issue Jan 25, 2024 · 0 comments · Fixed by #332
Closed
2 tasks done

BMI and request of scalar variables #331

verseve opened this issue Jan 25, 2024 · 0 comments · Fixed by #332
Assignees
Labels
bug Something isn't working

Comments

@verseve
Copy link
Member

verseve commented Jan 25, 2024

Wflow version checks

  • I have checked that this issue has not already been reported.

  • I have checked that this bug exists on the latest version of Wflow.

Reproducible Example

BMI.get_var_itemsize(model, "lateral.land.alpha_pow")

Current behaviour

{"status":"ERROR","error":"Wflow BMI get_var_itemsize failed
exception =
MethodError: no method matching view(::Float64, ::UnitRange{Int64}

Desired behaviour

Should give the item size (8) back. The error is thrown because a view is applied on a Float64 in BMI.get_value_ptr(model, name). For now, decided to not exchange scalar variables through BMI (there are only a few model parameters defined on a scalar grid).

Additional Context

No response

@verseve verseve added the bug Something isn't working label Jan 25, 2024
@verseve verseve self-assigned this Jan 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant