⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 mpdchkpyver.py

📁 mpi并行计算的c++代码 可用vc或gcc编译通过 可以用来搭建并行计算试验环境
💻 PY
字号:
#!/usr/bin/env python##   (C) 2001 by Argonne National Laboratory.#       See COPYRIGHT in top-level directory.#"""This program is not to be executed from the command line.  It is exec'd by mpdroot to verify the version of python before executinga 'regular' mpd pgm, e.g. mpdallexit."""from sys import version, exitif version[0] == '1' and version[1] == '.':    print "mpdchkpyver: your python version must be >= 2.2 ;"    print "  current version is:", version    exit(-1)##  These must be after 1.x version checkfrom time import ctime__author__ = "Ralph Butler and Rusty Lusk"__date__ = ctime()__version__ = "$Revision: 1.4 $"__credits__ = ""from sys     import argv, exitfrom os      import environ, execvpefrom mpdlib  import mpd_check_python_versionif __name__ == '__main__':    if len(argv) == 1  or  argv[1] == '-h'  or  argv[1] == '--help':        print __doc__	exit(-1)    else:        vinfo = mpd_check_python_version()        if vinfo:            print "mpdchkpyver: your python version must be >= 2.2 ; current version is:", vinfo            exit(-1)        if len(argv) > 1:            mpdpgm = argv[1] + '.py'            # print "CHKPYVER: PGM=:%s: ARGV[1:]=:%s:" % (mpdpgm,argv[1:])            try:                execvpe(mpdpgm,argv[1:],environ)    # client            except Exception, errinfo:                print 'mpdchkpyver: failed to exec %s; info=%s' % (mpdpgm,errinfo)                exit(-1)

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -