File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -198,11 +198,11 @@ def _write_hdf5(self, filepath):
198198 # NOTE: Despite the name "*_source_flag", the C++ binary expects
199199 # the number of time points in the source signal (not a boolean).
200200 # 0 = no source, >0 = number of time steps in the source signal.
201- "p_source_flag" : len (source .p [ 0 ]) if has_p else 0 ,
201+ "p_source_flag" : np . asarray (source .p ). shape [ - 1 ] if has_p else 0 ,
202202 "p0_source_flag" : int (has_p0 ),
203- "ux_source_flag" : len (source .ux [ 0 ]) if has_ux else 0 ,
204- "uy_source_flag" : len (source .uy [ 0 ]) if has_uy else 0 ,
205- "uz_source_flag" : len (source .uz [ 0 ]) if has_uz else 0 ,
203+ "ux_source_flag" : np . asarray (source .ux ). shape [ - 1 ] if has_ux else 0 ,
204+ "uy_source_flag" : np . asarray (source .uy ). shape [ - 1 ] if has_uy else 0 ,
205+ "uz_source_flag" : np . asarray (source .uz ). shape [ - 1 ] if has_uz else 0 ,
206206 "sxx_source_flag" : 0 ,
207207 "syy_source_flag" : 0 ,
208208 "szz_source_flag" : 0 ,
You can’t perform that action at this time.
0 commit comments