# -----------------------------------------------------------------------------------------------------------------
# BODY
# -----------------------------------------------------------------------------------------------------------------


# sixtrack_input_generator()


# simulations_launcher_func(epsilon_n,energy0,deltap0,xp0,yp0,sig0,iamp,eamp,n_samples,n_parts,wr_fr,SixTrack_folder,forts_folder,fort_n_list,folder_name,beta_star,beta_stary,alpha_x,alpha_y)


# data_storage_func( n_samples,n_parts,wr_fr,folder_name, dbname, tablename, main_folder)


activate_post_processing(
    dbname,
    tablename,
    dbschema,
    epsilon_n,
    energy0,
    iamp,
    eamp,
    n_samples,
    wr_fr,
    np.zeros(6),
    beta_star,
    beta_stary,
    alpha_x,
    alpha_y,
)
#------- dB

tablename = 'tracking_data' # DON'T MODIFY

dbschema = 'partID, turnID, cd, pdist, x, xp, y, yp, sig, deltap, energy'

dbname = '%s_samples%d-maxampl%d.db' %(main_folder,int(n_samples),int(eamp))



#-----------------------------------------------------------------------------------------------------------------
# BODY
#-----------------------------------------------------------------------------------------------------------------


#launch_madx_and_prepare_sixtrack_input(mask_file,seed,ip,bunch_charge,fort_n_list,main_folder)



#simulations_launcher_func(epsilon_n,energy0,deltap0,ip,seed,sig0,iamp,eamp,n_samples,n_parts,wr_fr,SixTrack_folder,forts_folder,fort_n_list,main_folder,folder_name)




#data_storage_func( n_samples,n_parts,wr_fr,folder_name, dbname, tablename, main_folder)




activate_post_processing(dbname, tablename, dbschema, epsilon_n, energy0, iamp, eamp, main_folder,wr_fr,ip,seed)