Skip to content

Commit

Permalink
Merge pull request #6 from mpaillassa/type_fix
Browse files Browse the repository at this point in the history
Float cast fix
  • Loading branch information
mpaillassa authored Jan 13, 2022
2 parents e03c947 + c406160 commit e829018
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
3 changes: 3 additions & 0 deletions maximask_and_maxitrack/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -282,6 +282,9 @@ def clean_grid(grid):
def image_norm(im):
"""Image preprocessing and normalization"""

# safety cast
im = im.astype(np.float32)

# preprocessing
np.place(im, np.isnan(im), 0)
np.place(im, im > 80000, 80000)
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

setup(
name="MaxiMask",
version="1.3.0",
version="1.3.1",
author="Maxime Paillassa",
author_email="[email protected]",
description="Convolutional neural networks to detect contaminants in astronomical images.",
Expand Down

0 comments on commit e829018

Please sign in to comment.