Skip to content

Commit

Permalink
remove constants
Browse files Browse the repository at this point in the history
  • Loading branch information
jettjaniak committed May 22, 2024
1 parent 972fc81 commit 4e4b969
Show file tree
Hide file tree
Showing 6 changed files with 9 additions and 13 deletions.
7 changes: 6 additions & 1 deletion src/delphi/__init__.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
from importlib.resources import files
from pathlib import Path
from typing import cast

from beartype.claw import beartype_this_package # <-- hype comes

beartype_this_package() # <-- hype goes

__version__ = "0.1.1"
__version__ = "0.2"
TEST_CONFIGS_DIR = cast(Path, files("delphi.test_configs"))
8 changes: 0 additions & 8 deletions src/delphi/constants.py

This file was deleted.

1 change: 0 additions & 1 deletion src/delphi/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ def hf_split_to_split_name(split: str) -> str:
return split.split("[")[0]


# TODO: test load_dataset functions
def load_dataset_split_features(
repo_id: str,
split: str,
Expand Down
2 changes: 1 addition & 1 deletion tests/train/config/test_config_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

import pytest

from delphi.constants import TEST_CONFIGS_DIR
from delphi import TEST_CONFIGS_DIR
from delphi.train.config.utils import (
_unoptionalize,
build_config_from_files_and_overrides,
Expand Down
2 changes: 1 addition & 1 deletion tests/train/test_train_step.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
from jaxtyping import Float
from transformers import PreTrainedModel

from delphi.constants import TEST_CONFIGS_DIR
from delphi import TEST_CONFIGS_DIR
from delphi.eval.utils import get_all_and_next_logprobs
from delphi.train.config import TrainingConfig
from delphi.train.config.utils import build_config_from_files_and_overrides
Expand Down
2 changes: 1 addition & 1 deletion tests/train/test_wandb_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
import transformers
from dacite import from_dict

from delphi.constants import TEST_CONFIGS_DIR
from delphi import TEST_CONFIGS_DIR
from delphi.train.config import TrainingConfig
from delphi.train.config.utils import build_config_from_files_and_overrides
from delphi.train.utils import ModelTrainingState, initialize_model_training_state
Expand Down

0 comments on commit 4e4b969

Please sign in to comment.