content[3:-4] for content in listdir if (content.startswith('TF') and content.endswith('dat')) ])) name = input('Choose your transfer Function\n') P_dir, MW_dir = detect_SubProcess(P_mode=1) os.chdir('./Source/MadWeight/transfer_function') change_tf.create_TF_main(name, 0, MW_dir) print(os.getcwd()) os.chdir('../../..') break if MWparam.run_opt['param']: create_param.Param_card(run_name=MWparam) MWparam.update_nb_card() Cards.create_include_file(MWparam) update_cuts_status(MWparam) if MWparam.run_opt['analyzer']: write_MadWeight.create_all_fortran_code(MWparam) if MWparam.run_opt['madweight_main']: Launch_all_SubProcess(MWparam) if MWparam.run_opt['plot']: import plot plot.Likelihood(mw_param=MWparam, auto=1) if MWparam['mw_run']['histo']: plot.Differential_Graph(MWparam, auto=1) if MWparam.run_opt['clean']: print('cleaning in progress ....') from clean import Clean_run
line=ff.readline() if line=='': raise FileInputException, 'incorect leshouche.inc at position '+filepos if pid_pat.search(line): pid_list=pid_pat.search(line).group('pid') pid_list=pid_list.replace(',',' ').split() #pass to a list of pid ff.close() break return pid_list # update for the card -transfer_card and madweight_card- if(__name__=="__main__"): import MW_param pos=os.getcwd() if pos.count('SubProcesses/MW_P') or pos.count('SubProcesses/P'): os.chdir('../..') MW_param.go_to_main_dir() MWparam=MW_param.MW_info('MadWeight_card.dat') create_include_file(MWparam) from create_run import update_cuts_status update_cuts_status(MWparam) if pos.count('SubProcesses/MW_P'): os.chdir(pos) os.system('make')