本文整理汇总了Python中oncotator.utils.ConfigUtils.ConfigUtils.buildReverseAlternativeDictionaryFromConfig方法的典型用法代码示例。如果您正苦于以下问题:Python ConfigUtils.buildReverseAlternativeDictionaryFromConfig方法的具体用法?Python ConfigUtils.buildReverseAlternativeDictionaryFromConfig怎么用?Python ConfigUtils.buildReverseAlternativeDictionaryFromConfig使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类oncotator.utils.ConfigUtils.ConfigUtils
的用法示例。
在下文中一共展示了ConfigUtils.buildReverseAlternativeDictionaryFromConfig方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: createConfigTableKeys
# 需要导入模块: from oncotator.utils.ConfigUtils import ConfigUtils [as 别名]
# 或者: from oncotator.utils.ConfigUtils.ConfigUtils import buildReverseAlternativeDictionaryFromConfig [as 别名]
def createConfigTableKeys(self, configParser, configTable):
# Parse fields from FORMAT section of the config file
"""
:param configParser:
:param configTable:
"""
table = ConfigUtils.buildReverseAlternativeDictionaryFromConfig(configParser, "INFO")
for ID, name in table.items():
configTable.addInfoFieldID(ID, name)
# Parse fields from FORMAT section of the config file
table = ConfigUtils.buildReverseAlternativeDictionaryFromConfig(configParser, "FORMAT")
for ID, name in table.items():
configTable.addFormatFieldID(ID, name)
# Parse fields from NOT_SPLIT_TAGS section of the config file
table = ConfigUtils.buildAlternateKeyDictionaryFromConfig(configParser, "NOT_SPLIT_TAGS")
for fieldType, IDs in table.items():
configTable.addFieldIDsToNotSplitSet(fieldType, IDs)
# Parse fields from SPLIT_TAGS section of the config file
table = ConfigUtils.buildAlternateKeyDictionaryFromConfig(configParser, "SPLIT_TAGS")
for fieldType, IDs in table.items():
configTable.addFieldIDsToSplitSet(fieldType, IDs)
示例2: createConfigTableKeys
# 需要导入模块: from oncotator.utils.ConfigUtils import ConfigUtils [as 别名]
# 或者: from oncotator.utils.ConfigUtils.ConfigUtils import buildReverseAlternativeDictionaryFromConfig [as 别名]
def createConfigTableKeys(self, configParser, configTable):
# Parse fields from FORMAT section of the config file
"""
:param configParser:
:param configTable:
"""
# Parse fields from INFO section of the config file
table = ConfigUtils.buildReverseAlternativeDictionaryFromConfig(configParser, "INFO")
for name, ID in table.items():
configTable.addInfoFieldName(name, ID)
table = ConfigUtils.buildReverseAlternativeDictionaryFromConfig(configParser, "FORMAT")
for name, ID in table.items():
configTable.addFormatFieldName(name, ID)
table = ConfigUtils.buildReverseAlternativeDictionaryFromConfig(configParser, "OTHER")
for name, ID in table.items():
configTable.addOtherFieldName(name, ID)
table = ConfigUtils.buildAlternateKeyDictionaryFromConfig(configParser, "INFO_DESCRIPTION")
for name, description in table.items():
configTable.addInfoFieldNameDescription(name, string.join(description, ","))
table = ConfigUtils.buildAlternateKeyDictionaryFromConfig(configParser, "FORMAT_DESCRIPTION")
for name, description in table.items():
configTable.addFormatFieldNameDescription(name, string.join(description, ","))
table = ConfigUtils.buildAlternateKeyDictionaryFromConfig(configParser, "FILTER_DESCRIPTION")
for name, description in table.items():
configTable.addFilterFieldNameDescription(name, string.join(description, ","))
table = ConfigUtils.buildAlternateKeyDictionaryFromConfig(configParser, "SPLIT_TAGS")
for fieldType, names in table.items():
configTable.addFieldNamesToSplitSet(fieldType, names)
table = ConfigUtils.buildAlternateKeyDictionaryFromConfig(configParser, "NOT_SPLIT_TAGS")
for fieldType, names in table.items():
configTable.addFieldNamesToNotSplitSet(fieldType, names)