Skip to content

Commit

Permalink
init RenameEntitySet col
Browse files Browse the repository at this point in the history
  • Loading branch information
singlesp committed Feb 5, 2025
1 parent febfe4b commit 9ae8987
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions cubids/tests/test_variant_numbering.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
from cubids.cubids import CuBIDS
from cubids.utils import assign_variants


@pytest.fixture
def sample_summary_df():
"""Create a sample summary DataFrame with multiple variant groups."""
Expand All @@ -22,6 +23,8 @@ def sample_summary_df():
# Add cluster columns
df["Cluster_EchoTime"] = [1, 2, 3, 1, 2]
df["Cluster_RepetitionTime"] = [1, 1, 1, 2, 2]
# Initialize RenameEntitySet column
df["RenameEntitySet"] = np.nan
return df

def test_variant_numbering_with_clusters(sample_summary_df):
Expand Down Expand Up @@ -50,6 +53,7 @@ def test_variant_numbering_mixed_clustering():
"EchoTime": ["0.05", "0.03", "0.07"],
"FlipAngle": ["90", "45", "90"],
"Cluster_EchoTime": [1, 2, 3],
"RenameEntitySet": [np.nan] * 3 # Initialize RenameEntitySet column
})

result = assign_variants(df, ["EchoTime", "FlipAngle"])
Expand All @@ -66,6 +70,7 @@ def test_variant_numbering_fieldmap():
"ParamGroup": [1, 2, 3],
"HasFieldmap": ["True", "False", "False"],
"UsedAsFieldmap": ["False", "True", "False"],
"RenameEntitySet": [np.nan] * 3 # Initialize RenameEntitySet column
})

result = assign_variants(df, ["HasFieldmap", "UsedAsFieldmap"])
Expand Down

0 comments on commit 9ae8987

Please sign in to comment.