当前位置: 首页>>代码示例>>Python>>正文


Python Settings.parse_command_line方法代码示例

本文整理汇总了Python中Settings.Settings.parse_command_line方法的典型用法代码示例。如果您正苦于以下问题:Python Settings.parse_command_line方法的具体用法?Python Settings.parse_command_line怎么用?Python Settings.parse_command_line使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Settings.Settings的用法示例。


在下文中一共展示了Settings.parse_command_line方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: Settings

# 需要导入模块: from Settings import Settings [as 别名]
# 或者: from Settings.Settings import parse_command_line [as 别名]
# XXX Gaussian: Figure out why post_hf lot is determined incorrectly and energies do not show up
#       For now this functionality does not look necessary, as we rarely use MP2 and CI, and there exist better programs for CC and MR
# XXX color logging:
#       Gives nothing to functionality but might add issues with OS compatibility
# XXX T1 diagnostics
#       Gaussian does not show t1 diagnostic by default, and it can not be activated in CBS-QB3
#       procedure, so for now showing t1 diagnostics would not be very helpful
# XXX write topology to .mol file
#       Using different file formats is inconvinient, and implementing topologies does not worth that mess.

# debug = 'DEBUG'

settings = Settings(from_config_file=True)
Top.settings = settings  # Here we modify the entire class that sits on the top of the hierarchy, so all new objects will have access to the settings

files = settings.parse_command_line(sys.argv)

if settings.debug:
    debug = 'DEBUG'
else:
    debug = 'INFO'

log = logging.getLogger('terse.py')
DebugLevel = getattr(logging, debug)
lf = '[%(levelname)s: %(funcName)s at %(filename)s +%(lineno)s] %(message)s'
logging.basicConfig(format=lf, level=DebugLevel)

# Prepare the file system
if not IO.prepare_folder(settings.OutputFolder):
    sys.exit()
开发者ID:talipovm,项目名称:terse,代码行数:32,代码来源:terse.py


注:本文中的Settings.Settings.parse_command_line方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。