@@ -191,15 +191,15 @@ def main():
191191 # print(f"patch {patch_id}")
192192 patch = phare_lvl [patch_id ]
193193
194- ph_bx = patch ["EM_B_x " ][:]
195- ph_by = patch ["EM_B_y " ][:]
196- ph_bz = patch ["EM_B_z " ][:]
194+ ph_x = patch ["f{phare_fn}_x " ][:]
195+ ph_y = patch ["f{phare_fn}_y " ][:]
196+ ph_z = patch ["f{phare_fn}_z " ][:]
197197
198198 box = boxFromPatch (patch )
199199 AMRBox .append (box )
200200 nbr_boxes += 1
201201 npx , npy , npz = nbrNodes (box )
202- b = toFlatPrimal (ph_bx , ph_by , ph_bz , npx , npy , npz )
202+ data = toFlatPrimal (ph_x , ph_y , ph_z , npx , npy , npz )
203203
204204 if first :
205205 # this is the first patch of the first time
@@ -208,16 +208,16 @@ def main():
208208 # which is unknown hence the None for maxshape
209209 # print(f"b shape :{b.shape[0]}")
210210 pointData_b = pointData_g .create_dataset (
211- "B " , data = b , maxshape = (None , 3 )
211+ "data " , data = data , maxshape = (None , 3 )
212212 )
213213 first = False
214214
215215 else :
216216 # dataset already created with shape (current_size,3)
217217 # we add b.shape[0] points (=npx*npy) to the first dim
218218 # hence need to resize the dataset.
219- pointData_b .resize (current_size + b .shape [0 ], axis = 0 )
220- pointData_b [current_size :, :] = b
219+ pointData_b .resize (current_size + data .shape [0 ], axis = 0 )
220+ pointData_b [current_size :, :] = data
221221 # pass
222222
223223 current_size += b .shape [0 ]
@@ -231,7 +231,7 @@ def main():
231231 lvl .create_dataset ("AMRBox" , data = AMRBox )
232232 steps_lvl .create_dataset ("AMRBoxOffset" , data = AMRBoxOffsets )
233233 steps_lvl .create_dataset ("NumberOfAMRBox" , data = step_nbrBoxes )
234- pointDataOffset_g .create_dataset ("B " , data = dataOffsets )
234+ pointDataOffset_g .create_dataset ("data " , data = dataOffsets )
235235
236236 vtk .close ()
237237
0 commit comments