@@ -39,18 +39,18 @@ def make_simulation_parameters(directory: Path):
3939 # define a binary planar sensor
4040 sensor = kSensor ()
4141 sensor_mask_array = np .zeros (N )
42- sensor_mask_array [0 , :, :] = 1 # Corrected to be a plane for 3D
42+ sensor_mask_array [0 , :, :] = 1 # Corrected to be a plane for 3D
4343 sensor .mask = sensor_mask_array
4444
4545 input_filename = directory / "kwave_input.h5"
4646 output_filename = directory / "kwave_output.h5"
4747 checkpoint_filename = directory / "kwave_checkpoint.h5"
4848
4949 simulation_options = SimulationOptions (
50- save_to_disk = True , # Must be true for kspaceFirstOrder3D
50+ save_to_disk = True , # Must be true for kspaceFirstOrder3D
5151 pml_size = PML_size ,
5252 pml_inside = False ,
53- smooth_p0 = False , # p0 is already smoothed
53+ smooth_p0 = False , # p0 is already smoothed
5454 data_cast = "single" ,
5555 input_filename = input_filename ,
5656 output_filename = output_filename ,
@@ -75,6 +75,7 @@ def test_kspaceFirstOrder3D_input_state_preservation():
7575 # Store original states of critical attributes for comparison
7676 original_source_p0 = deepcopy (source .p0 )
7777 original_sensor_mask = deepcopy (sensor .mask )
78+
7879
7980 # If source.p or source.u were time-varying, store their initial states too.
8081 # For this test, p0 is the main source attribute.
@@ -122,3 +123,4 @@ def test_kspaceFirstOrder3D_input_state_preservation():
122123 # Final check that attributes are still the same as the initial state
123124 assert np .array_equal (source .p0 , original_source_p0 ), "source.p0 was modified after second run"
124125 assert np .array_equal (sensor .mask , original_sensor_mask ), "sensor.mask was modified after second run"
126+
0 commit comments