def ks2_to_alf(ks_path, out_path, ampfactor=1, label=None, force=True): """ Convert Kilosort 2 output to ALF dataset for single probe data :param ks_path: :param out_path: :return: """ m = ephysqc.phy_model_from_ks2_path(ks_path) ac = alf.EphysAlfCreator(m) ac.convert(out_path, label=label, force=force, ampfactor=ampfactor)
def ks2_to_alf(ks_path, out_path, ampfactor=1, label=None, force=True): """ Convert Kilosort 2 output to ALF dataset for single probe data :param ks_path: :param out_path: :return: TODO change/remove `ampfactor` after seeing how amplitudes are calculated by ks2 """ m = ephysqc.phy_model_from_ks2_path(ks_path) ephysqc.unit_metrics_ks2(ks_path, m, save=True) ac = alf.EphysAlfCreator(m) ac.convert(out_path, label=label, force=force, ampfactor=ampfactor)
def ks2_to_alf(ks_path, bin_path, out_path, bin_file=None, ampfactor=1, label=None, force=True): """ Convert Kilosort 2 output to ALF dataset for single probe data :param ks_path: :param bin_path: path of raw data :param out_path: :return: """ m = ephysqc.phy_model_from_ks2_path(ks2_path=ks_path, bin_path=bin_path, bin_file=bin_file) ephysqc.spike_sorting_metrics_ks2(ks_path, m, save=True) ac = alf.EphysAlfCreator(m) ac.convert(out_path, label=label, force=force, ampfactor=ampfactor)