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

Floating point constants get interpreted as doubles #287

Closed
jdries opened this issue May 2, 2024 · 0 comments
Closed

Floating point constants get interpreted as doubles #287

jdries opened this issue May 2, 2024 · 0 comments
Assignees

Comments

@jdries
Copy link
Contributor

jdries commented May 2, 2024

Python always works in float64 by default, so when a user uses a constant like 1.0 in a computation, the result ends up in float64, even if this is not required by the precision provided.

To save memory, it seems better to be more conservative and try to stay in float32 if possible.

Part of the problem is also caused by the implementation of array_create, which does not force datatypes to something constant.

jdries added a commit that referenced this issue May 2, 2024
@jdries jdries self-assigned this May 2, 2024
jdries added a commit that referenced this issue May 3, 2024
jdries added a commit that referenced this issue May 6, 2024
jdries added a commit to Open-EO/openeo-geopyspark-driver that referenced this issue May 6, 2024
jdries added a commit to Open-EO/openeo-geopyspark-driver that referenced this issue May 6, 2024
@jdries jdries closed this as completed May 6, 2024
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

1 participant