Skip to content

Commit 5dcaeda

Browse files
committed
update energy handling in stf VHEE generator and tests
1 parent 548fc67 commit 5dcaeda

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

matRad/steering/matRad_StfGeneratorParticleVHEE.m

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,7 @@
4949
else
5050
beam.VHEEenergy = this.energy;
5151
end
52+
this.energy = beam.VHEEenergy;
5253
% Optional: check if that energy is in the machine data
5354
if isfield(this.machine.data,'energies') && ~isempty(this.machine.data.energies)
5455
if ~ismember(beam.VHEEenergy, this.machine.data.energies)

test/steering/test_stfGeneratorVHEE.m

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,9 @@ function test_basic_construct()
1010

1111
function test_pln_construct()
1212
load VHEE_testData.mat
13+
pln.propStf.energy = 150;
1314
stfGen = matRad_StfGeneratorParticleVHEE(pln);
1415
stfGen.isAvailable(pln);
15-
pln.propStf.energy = 150;
1616
assertTrue(isa(stfGen, 'matRad_StfGeneratorParticleVHEE'));
1717
assertEqual(stfGen.gantryAngles, pln.propStf.gantryAngles);
1818
assertEqual(stfGen.couchAngles, pln.propStf.couchAngles);
@@ -25,9 +25,9 @@ function test_pln_construct()
2525
function test_pln_construct_focused()
2626
load VHEE_testData.mat
2727
pln.machine = 'Focused';
28+
pln.propStf.energy = 150;
2829
stfGen = matRad_StfGeneratorParticleVHEE(pln);
2930
stfGen.isAvailable(pln);
30-
pln.propStf.energy = 150;
3131
assertTrue(isa(stfGen, 'matRad_StfGeneratorParticleVHEE'));
3232
assertEqual(stfGen.gantryAngles, pln.propStf.gantryAngles);
3333
assertEqual(stfGen.couchAngles, pln.propStf.couchAngles);

0 commit comments

Comments
 (0)