Skip to content

Commit

Permalink
fix: more fix
Browse files Browse the repository at this point in the history
  • Loading branch information
paquiteau committed Feb 11, 2025
1 parent 0933df2 commit 545ca47
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 12 deletions.
1 change: 0 additions & 1 deletion src/snake/core/handlers/fov.py
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,6 @@ def get_static(self, phantom: Phantom, sim_conf: SimConfig) -> Phantom:
zoom_factor=zoom_factor,
)
if phantom.smaps is not None:
return Phantom.from_masks(new_masks, sim_conf)
new_smaps = np.zeros(
(
phantom.smaps.shape[0],
Expand Down
23 changes: 12 additions & 11 deletions src/snake/core/phantom/static.py
Original file line number Diff line number Diff line change
Expand Up @@ -227,18 +227,19 @@ def to_mrd_dataset(
),
)
# Add the smaps
dataset.append_image(
"smaps",
mrd.image.Image(
head=mrd.image.ImageHeader(
matrixSize=mrd.xsd.matrixSizeType(*self.smaps.shape[1:]),
fieldOfView_mm=mrd.xsd.fieldOfViewMm(*sim_conf.fov_mm),
channels=len(self.smaps),
acquisition_time_stamp=0,
if self.smaps is not None:
dataset.append_image(
"smaps",
mrd.image.Image(
head=mrd.image.ImageHeader(
matrixSize=mrd.xsd.matrixSizeType(*self.smaps.shape[1:]),
fieldOfView_mm=mrd.xsd.fieldOfViewMm(*sim_conf.fov_mm),
channels=len(self.smaps),
acquisition_time_stamp=0,
),
data=self.smaps,
),
data=self.smaps,
),
)
)
return dataset

@classmethod
Expand Down

0 comments on commit 545ca47

Please sign in to comment.