equinor / equinor/ert

Be more precise when type hinting numpy floats

Open
#8,237 0 comments 0 reactions 0 assignees View on GitHub
enhancement
Dominant language
Python
Stars
161
Forks
140
Avg merge
2d 1h
Merged PRs (30d)
138

Description

Numpy 2 deprecates the `np.float_` alias for `np.float64`, and since we often use `np.float32` we should type hint better to indicate when the variables/return types might be `np.float32` vs `np.float64` .

Contributor guide

Open the contributing guide

Research direction

Start by locating type hints that use np.float_, np.float32, or np.float64, then inspect the surrounding annotations and their callers. Done means the affected variables and return types distinguish float32 from float64 and no longer rely on the deprecated np.float_ alias.

Written by the indexing model from the issue text.

Assessment

Tech stack
numpy, python
Domain
data
Issue type
Refactor
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.