Skip to content

Commit c53b029

Browse files
Remove volumes list from Subject (#91)
We now track volumes inside a volumes subdirectory, just like we do with sessions.
1 parent acc4382 commit c53b029

File tree

2 files changed

+1
-7
lines changed

2 files changed

+1
-7
lines changed

src/openlifu/db/subject.py

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import json
22
from dataclasses import dataclass, field
33
from pathlib import Path
4-
from typing import List, Optional
4+
from typing import Optional
55

66
from openlifu.io.dict_conversion import DictMixin
77
from openlifu.util.strings import sanitize
@@ -19,7 +19,6 @@ class Subject(DictMixin):
1919
"""
2020
id: Optional[str] = None
2121
name: Optional[str] = None
22-
volumes: List[str] = field(default_factory=list)
2322
attrs: dict = field(default_factory=dict)
2423

2524
def __post_init__(self):
@@ -29,10 +28,6 @@ def __post_init__(self):
2928
self.id = sanitize(self.name, "snake")
3029
if self.name is None:
3130
self.name = self.id
32-
if isinstance(self.volumes, str):
33-
self.volumes = [self.volumes]
34-
else:
35-
self.volumes = list(self.volumes)
3631

3732
@staticmethod
3833
def from_file(filename):
Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
{
22
"id": "example_subject",
33
"name": "Example Subject",
4-
"volumes": ["example_volume"],
54
"attrs": {}
65
}

0 commit comments

Comments
 (0)