The pvloop.py module#

Summary#

write_pvloop_pngs

Write PV loop figures to a PNG file.

generate_pvloop

Generate PV loop figures from the ICVOUT file.

Description#

Get pressure-volume (PV) loop from the LS-DYNA ICVOUT file.

Module detail#

pvloop.write_pvloop_pngs(pressure: numpy.ndarray, volume: numpy.ndarray, save_to: str) None#

Write PV loop figures to a PNG file.

Parameters:
pressurenp.ndarray

Pressure array.

volumenp.ndarray

Volume array.

save_tostr

Directory to save the file to.

pvloop.generate_pvloop(f: str, out_dir: str, t_to_keep: float = 800) None#

Generate PV loop figures from the ICVOUT file.

Parameters:
fstr

Path to the binout file.

out_dirstr

Directory to save the file to.

t_to_keepfloat, optional

Time to keep from the end. The default is 800, which is the last heart beat.

pvloop.CV_NAME = ['LV', 'RV', 'LA', 'RA']#