0.1.167
This commit is contained in:
		| @@ -1,7 +1,7 @@ | ||||
| [metadata] | ||||
| # replace with your username: | ||||
| name = guan | ||||
| version = 0.1.166 | ||||
| version = 0.1.167 | ||||
| author = guanjihuan | ||||
| author_email = guanjihuan@163.com | ||||
| description = An open source python package | ||||
|   | ||||
| @@ -1,6 +1,6 @@ | ||||
| Metadata-Version: 2.4 | ||||
| Name: guan | ||||
| Version: 0.1.166 | ||||
| Version: 0.1.167 | ||||
| Summary: An open source python package | ||||
| Home-page: https://py.guanjihuan.com | ||||
| Author: guanjihuan | ||||
|   | ||||
| @@ -129,6 +129,16 @@ def make_sh_file_for_bsub(sh_filename='a', command_line='python a.py', cpu_num=1 | ||||
|     with open(sh_filename+'.sh', 'w') as f: | ||||
|         f.write(sh_content) | ||||
|  | ||||
| # qsub 提交任务(PBS) | ||||
| def qsub_task(filename='a', file_format='.sh'): | ||||
|     import os | ||||
|     os.system('qsub '+filename+file_format) | ||||
|  | ||||
| # bsub 提交任务(LSF) | ||||
| def bsub_task(filename='a', file_format='.sh'): | ||||
|     import os | ||||
|     os.system('bsub < '+filename+file_format) | ||||
|  | ||||
| # 复制.py和.sh文件,然后提交任务,实现半手动并行(PBS) | ||||
| def copy_py_sh_file_and_qsub_task(parameter_array, py_filename='a', old_str_in_py='parameter = 0', new_str_in_py='parameter = ', sh_filename='a', task_name='task'): | ||||
|     import os | ||||
|   | ||||
		Reference in New Issue
	
	Block a user