Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
tchaton committed Jul 16, 2024
1 parent 1edbe00 commit d97ddd3
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
5 changes: 2 additions & 3 deletions src/litdata/constants.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@

import os
from pathlib import Path
from typing import Dict

import numpy as np
import torch
Expand Down Expand Up @@ -71,17 +72,15 @@
np.float16,
np.float32,
np.float64,
np.longdouble,
np.complex64,
np.complex128,
np.clongdouble,
bool,
object,
bytes,
str,
np.void,
]
_NUMPY_DTYPES_MAPPING = {i: np.dtype(v) for i, v in enumerate(_NUMPY_SCTYPES)}
_NUMPY_DTYPES_MAPPING: Dict[int, np.dtype] = {i: np.dtype(v) for i, v in enumerate(_NUMPY_SCTYPES)}

_TIME_FORMAT = "%Y-%m-%d_%H-%M-%S.%fZ"
_IS_IN_STUDIO = bool(os.getenv("LIGHTNING_CLOUD_PROJECT_ID", None)) and bool(os.getenv("LIGHTNING_CLUSTER_ID", None))
Expand Down
2 changes: 1 addition & 1 deletion tests/streaming/test_serializer.py
Original file line number Diff line number Diff line change
Expand Up @@ -208,7 +208,7 @@ def test_assert_no_header_numpy_serializer():
assert serializer.can_serialize(t)
data, name = serializer.serialize(t)
try:
assert name == "no_header_numpy:11"
assert name == "no_header_numpy:10"
except AssertionError as e: # debug what np.core.sctypes looks like on Windows
raise ValueError(np.core.sctypes) from e
assert serializer._dtype is None
Expand Down

0 comments on commit d97ddd3

Please sign in to comment.