Skip to content

Commit

Permalink
Update KomaMRIFiles/src/Sequence/WritePulseq.jl
Browse files Browse the repository at this point in the history
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
  • Loading branch information
beorostica and github-actions[bot] authored Apr 11, 2024
1 parent 2afd1fb commit 4449abe
Showing 1 changed file with 13 additions and 2 deletions.
15 changes: 13 additions & 2 deletions KomaMRIFiles/src/Sequence/WritePulseq.jl
Original file line number Diff line number Diff line change
Expand Up @@ -256,8 +256,19 @@ function write_seq(seq::Sequence, filename)
end

# Define the table to be written for the [SHAPES] section
shapefull_data_id = [shapeunique_data_id_i for shapeunique_data_id [rfunique_abs_id, rfunique_ang_id, rfunique_tim_id, gradunique_amp_id, gradunique_tim_id] for shapeunique_data_id_i shapeunique_data_id]
shape_data_id_num = [(length(compress(data)) == length(data) ? data : compress(data), id, length(data)) for (data, id) shapefull_data_id]
shapefull_data_id = [
shapeunique_data_id_i for shapeunique_data_id in [
rfunique_abs_id,
rfunique_ang_id,
rfunique_tim_id,
gradunique_amp_id,
gradunique_tim_id,
] for shapeunique_data_id_i in shapeunique_data_id
]
shape_data_id_num = [
(length(compress(data)) == length(data) ? data : compress(data), id, length(data))
for (data, id) in shapefull_data_id
]

# Write the .seq file
open(filename, "w") do fid
Expand Down

0 comments on commit 4449abe

Please sign in to comment.