simulariumio/physicell/physicell_converter.py
def _load_data(path_to_output_dir: str, nth_timestep_to_read: int) -> np.ndarray:
        """
        Load simulation data from PhysiCell MultiCellDS XML files
        """
        files = Path(path_to_output_dir).glob("*output*.xml")
        file_mapping = {}
        for f in files:
            index = int(f.name[f.name.index("output") + 6 :].split(".")[0])
            if index % nth_timestep_to_read == 0:
                file_mapping[index] = f
        data = []
        for t, xml_file in sorted(file_mapping.items()):
            data.append(pyMCDS(xml_file.name, False, path_to_output_dir))
        return np.array(data)

        Load simulation data from PhysiCell MultiCellDS XML files
        
Load simulation data from PhysiCell MultiCellDS XML files
Load simulation data from PhysiCell MultiCellDS XML files
def _load_data(path_to_output_dir: str, nth_timestep_to_read: int) -> np.ndarray:
        files = Path(path_to_output_dir).glob("*output*.xml")
        file_mapping = {}
        for f in files:
            index = int(f.name[f.name.index("output") + 6 :].split(".")[0])
            if index % nth_timestep_to_read == 0:
                file_mapping[index] = f
        data = []
        for t, xml_file in sorted(file_mapping.items()):
            data.append(pyMCDS(xml_file.name, False, path_to_output_dir))
        return np.array(data)
def _load_data ( path_to_output_dir : str , nth_timestep_to_read : int ) -> np . ndarray : files = Path ( path_to_output_dir ) . glob ( "*output*.xml" ) file_mapping = { } for f in files : index = int ( f . name [ f . name . index ( "output" ) + 6 : ] . split ( "." ) [ 0 ] ) if index % nth_timestep_to_read == 0 : file_mapping [ index ] = f data = [ ] for t , xml_file in sorted ( file_mapping . items ( ) ) : data . append ( pyMCDS ( xml_file . name , False , path_to_output_dir ) ) return np . array ( data )
Load simulation data from PhysiCell MultiCellDS XML files
Load simulation data from PhysiCell MultiCellDS XML files
"""
        Load simulation data from PhysiCell MultiCellDS XML files
        """
path_to_output_dir
str
nth_timestep_to_read
int