Skip to content

Commit

Permalink
Remove naive scaling logic
Browse files Browse the repository at this point in the history
  • Loading branch information
gnodar01 committed Dec 10, 2024
1 parent 0c62726 commit eeb8c2e
Showing 1 changed file with 0 additions and 12 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -230,18 +230,6 @@ def normalize_to_float32(data, in_range=None, wants_inscale=False):
return data, scale
return data

# TODO - 4955: Temporary. This needs to be fixed, it is currently very naive
@staticmethod
def naive_scale(data):
if numpy.issubdtype(data.dtype, numpy.integer):
scale = numpy.iinfo(data.dtype).max
elif numpy.issubdtype(data.dtype, numpy.floating): # assume
# assume float is already normalized
scale = 1
else:
raise NotImplementedError(f"Unsupported dtype: {data.dtype}")
return scale

@property
def series(self):
return self.__series
Expand Down

0 comments on commit eeb8c2e

Please sign in to comment.