Skip to content

Commit

Permalink
Merge pull request #2773 from activeloopai/upcasting_logic_fix
Browse files Browse the repository at this point in the history
fix upcasting logic
  • Loading branch information
activesoull committed Feb 16, 2024
2 parents 8fff66c + ca29e9c commit a906532
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions deeplake/enterprise/dataloader.py
Expand Up @@ -698,6 +698,12 @@ def __is_upcast_needed(self, dataset, tensors) -> bool:

if dtype.type in [np.uint16, np.uint32, np.uint64]:
return True

if hasattr(dtype, "type"):
if isinstance(
dtype.type, (type(np.uint16), type(np.uint32), type(np.uint64))
):
return True
return False

def __create_dummy_dataloader(
Expand Down

0 comments on commit a906532

Please sign in to comment.