Skip to content

Commit

Permalink
Removed redundant checks that are now performed in singlepp itself.
Browse files Browse the repository at this point in the history
  • Loading branch information
LTLA committed Dec 28, 2024
1 parent a2827b4 commit 660431e
Show file tree
Hide file tree
Showing 4 changed files with 0 additions and 8 deletions.
3 changes: 0 additions & 3 deletions src/singler/classify_integrated.py
Original file line number Diff line number Diff line change
Expand Up @@ -77,9 +77,6 @@ def classify_integrated(
if isinstance(test_data, summarizedexperiment.SummarizedExperiment):
test_data = test_data.assay(assay_type)

if test_data.shape[0] != integrated_prebuilt._test_num_features: # TODO: move to singlepp.
raise ValueError("number of rows in 'test_data' is not consistent with 'test_features=' used to create 'integrated_prebuilt'")

ref_labs = integrated_prebuilt.reference_labels
if len(results) != len(ref_labs):
raise ValueError("length of 'results' should equal the number of references")
Expand Down
3 changes: 0 additions & 3 deletions src/singler/classify_single.py
Original file line number Diff line number Diff line change
Expand Up @@ -66,9 +66,6 @@ def classify_single(
if isinstance(test_data, summarizedexperiment.SummarizedExperiment):
test_data = test_data.assay(assay_type)

if test_data.shape[0] != ref_prebuilt._test_num_features: # TODO: move to singlepp
raise ValueError("number of rows in 'test_data' is not consistent with 'test_features=' used to create 'ref_prebuilt'")

test_ptr = mattress.initialize(test_data)

best, raw_scores, delta = lib.classify_single(
Expand Down
1 change: 0 additions & 1 deletion src/singler/train_integrated.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ class TrainedIntegratedReferences:
def __init__(self, ptr: int, ref_labels: list, test_num_features: int):
self._ptr = ptr
self._labels = ref_labels
self._test_num_features = test_num_features # TODO: move to singlepp.

@property
def reference_labels(self) -> list:
Expand Down
1 change: 0 additions & 1 deletion src/singler/train_single.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@ def __init__(
self._features = features
self._labels = labels
self._markers = markers
self._test_num_features = test_num_features # TODO: move to singlepp.

def num_markers(self) -> int:
"""
Expand Down

0 comments on commit 660431e

Please sign in to comment.