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

GRIDEDIT-976 double int interpolation types in meshkernelpy #171

Merged

Conversation

lucacarniato
Copy link
Contributor

No description provided.

self.value_type: int = InterpolationValues.FLOAT
self.values: ndarray = np.asarray(values, dtype=np.float32)
elif values.dtype == np.int16:
if values.dtype == np.int16:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you can use match case and combine the default case with np.float32

@@ -1932,7 +1947,17 @@ def test_mesh2d_refine_based_on_gridded_samples_coastline():
]
)

values_np = values_2d.flatten().astype(np.float32)
if interpolation_type == InterpolationValues.SHORT:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same

@lucacarniato lucacarniato merged commit 89a44bc into main May 8, 2024
8 of 11 checks passed
@lucacarniato lucacarniato deleted the feature/GRIDEDIT-976_double_int_interpolation_types branch May 8, 2024 13:54
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

Successfully merging this pull request may close these issues.

None yet

2 participants