comparison calculate_pore_diameter_aqp.py @ 12:0948dffa06f9 draft

"planemo upload for repository https://github.com/mesocentre-clermont-auvergne/aubi_piaf commit 9167288bf44ec486f68dade6f4fca41728690dd6-dirty"
author agpetit
date Tue, 14 Jun 2022 13:21:06 +0000
parents 113c9904d083
children cfc1508ad873
comparison
equal deleted inserted replaced
11:24449f8d1687 12:0948dffa06f9
81 ) 81 )
82 parser.add_argument( 82 parser.add_argument(
83 "--xtc_file_ext", type=str, nargs=1, help="""My input .xtc file""" 83 "--xtc_file_ext", type=str, nargs=1, help="""My input .xtc file"""
84 ) 84 )
85 parser.add_argument( 85 parser.add_argument(
86 "-w", "--work_directory", type=str, nargs=1, 86 "-w", "--work_directory", type=str, default="./",
87 help="""It's work Directory""" 87 help="""It's work Directory"""
88 ) 88 )
89 parser.add_argument( 89 parser.add_argument(
90 "-od", 90 "-od",
91 "--output_directory", 91 "--output_directory",
1052 else: 1052 else:
1053 resid_arr2 = args.arr_second 1053 resid_arr2 = args.arr_second
1054 df_final = create_final_dataframe(resid_arr1, resid_arr2, 1054 df_final = create_final_dataframe(resid_arr1, resid_arr2,
1055 resid_npa1, resid_npa2, u) 1055 resid_npa1, resid_npa2, u)
1056 if len(output_directory) > 2: 1056 if len(output_directory) > 2:
1057 if not os.path.exists(output_directory): 1057 try:
1058 os.makedirs(output_directory) 1058 os.makedirs(output_directory, exist_ok=True)
1059 except OSError:
1060 print("Directory '%s' can not be created")
1059 os.chdir(output_directory) 1061 os.chdir(output_directory)
1060 if len(output) > 2: 1062 if len(output) > 2:
1061 df_final.to_csv(output, sep="\t", index=False) 1063 df_final.to_csv(output, sep="\t", index=False)
1062 else: 1064 else:
1063 file_name_tabular = out_file_name + "PairDist.tabular" 1065 file_name_tabular = out_file_name + "PairDist.tabular"