def analysis_a_new(nwb_a, tmpdir_factory): save_path = str(tmpdir_factory.mktemp("session_a") / "session_a_new.h5") logging.debug("running analysis a") session_analysis = SessionAnalysis(nwb_a, save_path) session_analysis.session_a(plot_flag=False, save_flag=True) logging.debug("done running analysis a") logging.debug(save_path) yield save_path
def analysis_a_new(nwb_a): with tempfile.NamedTemporaryFile(delete=True) as tf: save_path = tf.name logging.debug("running analysis a") session_analysis = SessionAnalysis(nwb_a, save_path) session_analysis.session_a(plot_flag=False, save_flag=True) logging.debug("done running analysis a") logging.debug(save_path) yield save_path if os.path.exists(save_path): os.remove(save_path)