Skip to content

Commit

Permalink
add str
Browse files Browse the repository at this point in the history
  • Loading branch information
levongh committed May 11, 2023
1 parent 88be4b2 commit baa69dc
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
2 changes: 2 additions & 0 deletions deeplake/integrations/pytorch/shuffle_buffer.py
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,8 @@ def _num_torch_tensors(self, sample):
return 1
elif isinstance(sample, bytes):
return 0
elif isinstance(sample, str):
return 0
elif isinstance(sample, dict):
return sum(self._num_torch_tensors(tensor) for tensor in sample.values())
elif isinstance(sample, Sequence):
Expand Down
2 changes: 2 additions & 0 deletions deeplake/requirements/tests.txt
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,5 @@ boto3-stubs[essential]
lz4
rich
wandb

pandas; python_version >= '3.11' and sys_platform == 'win32'

0 comments on commit baa69dc

Please sign in to comment.