def ProcessOptions():
    """Process and validate command line arguments and options"""

    MiscUtil.PrintInfo("Processing options...")

    # Validate options...
    ValidateOptions()

    OptionsInfo["Infile"] = Options["--infile"]
    OptionsInfo["InfileParams"] = MiscUtil.ProcessOptionInfileParameters(
        "--infileParams", Options["--infileParams"], Options["--infile"])

    OptionsInfo["Outfile"] = Options["--outfile"]
    OptionsInfo["OutfileParams"] = MiscUtil.ProcessOptionOutfileParameters(
        "--outfileParams", Options["--outfileParams"], Options["--infile"],
        Options["--outfile"])

    OptionsInfo["Overwrite"] = Options["--overwrite"]

    OptionsInfo["CountMode"] = False
    if re.match("^count$", Options["--mode"], re.I):
        OptionsInfo["CountMode"] = True

    OptionsInfo["NegateMatch"] = False
    if re.match("^yes$", Options["--negate"], re.I):
        OptionsInfo["NegateMatch"] = True

    OptionsInfo["PAINSMode"] = Options["--painsMode"]
Beispiel #2
0
def ProcessOptions():
    """Process and validate command line arguments and options"""
    
    MiscUtil.PrintInfo("Processing options...")
    
    # Validate options...
    ValidateOptions()
    
    OptionsInfo["Infile"] = Options["--infile"]
    OptionsInfo["InfileParams"] = MiscUtil.ProcessOptionInfileParameters("--infileParams", Options["--infileParams"], Options["--infile"])
    
    OptionsInfo["Outfile"] = Options["--outfile"]
    OptionsInfo["OutfileParams"] = MiscUtil.ProcessOptionOutfileParameters("--outfileParams", Options["--outfileParams"], Options["--infile"], Options["--outfile"])
    
    OptionsInfo["Overwrite"] = Options["--overwrite"]

    OptionsInfo["CountMode"] = False
    if re.match("^count$", Options["--mode"], re.I):
        OptionsInfo["CountMode"] = True
    
    # Setup outfile for writing out duplicates...
    OptionsInfo["DuplicatesOutfile"] = ""
    if not OptionsInfo["CountMode"] :
        FileDir, FileName, FileExt = MiscUtil.ParseFileName(OptionsInfo["Outfile"])
        OptionsInfo["DuplicatesOutfile"] = "%sDuplicates.%s" % (FileName, FileExt)

    OptionsInfo["UseChirality"] = False
    if re.match("^yes$", Options["--useChirality"], re.I):
        OptionsInfo["UseChirality"] = True
def ProcessOptions():
    """Process and validate command line arguments and options"""

    MiscUtil.PrintInfo("Processing options...")

    # Validate options...
    ValidateOptions()

    OptionsInfo["Mode"] = Options["--mode"]
    OptionsInfo["Fingerprints"] = Options["--fingerprints"]

    OptionsInfo["ClusteringMethod"] = Options["--clusteringMethod"]
    ProcessClusteringMethodParameter()

    OptionsInfo["NumMols"] = int(Options["--numMols"])

    OptionsInfo["Infile"] = Options["--infile"]
    OptionsInfo["InfileParams"] = MiscUtil.ProcessOptionInfileParameters(
        "--infileParams", Options["--infileParams"], Options["--infile"])

    OptionsInfo["Outfile"] = Options["--outfile"]
    OptionsInfo["OutfileParams"] = MiscUtil.ProcessOptionOutfileParameters(
        "--outfileParams", Options["--outfileParams"], Options["--infile"],
        Options["--outfile"])

    OptionsInfo["Overwrite"] = Options["--overwrite"]

    OptionsInfo["SimilarityMetric"] = Options["--similarityMetric"]
    ProcessSimilarityMetricParameter()

    OptionsInfo["ParamsFingerprints"] = Options["--paramsFingerprints"]
    ProcessFingerprintsParameters()
Beispiel #4
0
def ProcessOptions():
    """Process and validate command line arguments and options"""
    
    MiscUtil.PrintInfo("Processing options...")
    
    # Validate options...
    ValidateOptions()
    
    OptionsInfo["Infile"] = Options["--infile"]
    OptionsInfo["InfileParams"] = MiscUtil.ProcessOptionInfileParameters("--infileParams", Options["--infileParams"], Options["--infile"])
    
    OptionsInfo["Outfile"] = Options["--outfile"]
    OptionsInfo["OutfileParams"] = MiscUtil.ProcessOptionOutfileParameters("--outfileParams", Options["--outfileParams"], Options["--infile"], Options["--outfile"])
    
    FileDir, FileName, FileExt = MiscUtil.ParseFileName(Options["--outfile"])
    OutfileFiltered = "%s_Filtered.%s" % (FileName, FileExt)
    OptionsInfo["OutfileFiltered"] = OutfileFiltered
    OptionsInfo["OutfileFilteredMode"] = True if re.match("^yes$", Options["--outfileFiltered"], re.I) else False
    
    OptionsInfo["Overwrite"] = Options["--overwrite"]

    OptionsInfo["CountMode"] = True if re.match("^count$", Options["--mode"], re.I) else False
    OptionsInfo["NegateMatch"] = True if re.match("^yes$", Options["--negate"], re.I) else False

    OptionsInfo["MPMode"] = True if re.match("^yes$", Options["--mp"], re.I) else False
    OptionsInfo["MPParams"] = MiscUtil.ProcessOptionMultiprocessingParameters("--mpParams", Options["--mpParams"])
    
    OptionsInfo["AlertsMode"] = Options["--alertsMode"]
    ProcessChEMBLAlertsMode()
def ProcessOptions():
    """Process and validate command line arguments and options"""

    MiscUtil.PrintInfo("Processing options...")

    # Validate options...
    ValidateOptions()

    OptionsInfo["DiscardNonPhysical"] = True
    if re.match("^no$", Options["--discardNonPhysical"], re.I):
        OptionsInfo["DiscardNonPhysical"] = False

    OptionsInfo["Mode"] = Options["--mode"]
    UnassignedOnly = True
    if re.match("^All$", Options["--mode"], re.I):
        UnassignedOnly = False
    OptionsInfo["UnassignedOnly"] = UnassignedOnly

    OptionsInfo["Infile"] = Options["--infile"]
    OptionsInfo["InfileParams"] = MiscUtil.ProcessOptionInfileParameters(
        "--infileParams", Options["--infileParams"], Options["--infile"])

    OptionsInfo["Outfile"] = Options["--outfile"]
    OptionsInfo["OutfileParams"] = MiscUtil.ProcessOptionOutfileParameters(
        "--outfileParams", Options["--outfileParams"], Options["--infile"],
        Options["--outfile"])

    OptionsInfo["Overwrite"] = Options["--overwrite"]

    OptionsInfo["MaxIsomers"] = int(Options["--maxIsomers"])
Beispiel #6
0
def ProcessOptions():
    """Process and validate command line arguments and options"""

    MiscUtil.PrintInfo("Processing options...")

    # Validate options...
    ValidateOptions()

    OptionsInfo["Infile"] = Options["--infile"]
    OptionsInfo["InfileParams"] = MiscUtil.ProcessOptionInfileParameters(
        "--infileParams", Options["--infileParams"], Options["--infile"])

    OptionsInfo["Outfile"] = Options["--outfile"]
    OptionsInfo["OutfileParams"] = MiscUtil.ProcessOptionOutfileParameters(
        "--outfileParams", Options["--outfileParams"], Options["--infile"],
        Options["--outfile"])

    OptionsInfo["Overwrite"] = Options["--overwrite"]

    OptionsInfo["CountMode"] = True if re.match("^count$", Options["--mode"],
                                                re.I) else False

    # Setup outfile for writing out molecule number for invalid molecules...
    OptionsInfo["InvalidMolsOutfile"] = ""
    if not OptionsInfo["CountMode"]:
        FileDir, FileName, FileExt = MiscUtil.ParseFileName(
            OptionsInfo["Outfile"])
        OptionsInfo["InvalidMolsOutfile"] = "%sInvalidMols.csv" % (FileName)
def ProcessOptions():
    """Process and validate command line arguments and options"""
    
    MiscUtil.PrintInfo("Processing options...")
    
    # Validate options...
    ValidateOptions()
    
    OptionsInfo["CalcRMSD"] = Options["--calcRMSD"]
    OptionsInfo["UseBestRMSD"] = False
    if re.match("^BestRMSD$", OptionsInfo["CalcRMSD"], re.I):
        OptionsInfo["UseBestRMSD"] = True
    
    OptionsInfo["MaxIters"] = int(Options["--maxIters"])
    
    OptionsInfo["Mode"] = Options["--mode"]
    
    OptionsInfo["RefFile"] = Options["--reffile"]
    OptionsInfo["ProbeFile"] = Options["--probefile"]

    # No need for any RDKit specific --outfileParams....
    OptionsInfo["InfileParams"] = MiscUtil.ProcessOptionInfileParameters("--infileParams", Options["--infileParams"])
    
    OptionsInfo["Outfile"] = Options["--outfile"]
    
    OptionsInfo["Overwrite"] = Options["--overwrite"]
    
    OptionsInfo["OutDelim"] = " "
    if MiscUtil.CheckFileExt(OptionsInfo["Outfile"], "csv"):
        OptionsInfo["OutDelim"] = ","
    elif MiscUtil.CheckFileExt(OptionsInfo["Outfile"], "tsv txt"):
        OptionsInfo["OutDelim"] = "\t"
    else:
        MiscUtil.PrintError("The file name specified , %s, for option \"--outfile\" is not valid. Supported file formats: csv tsv txt\n" % (OptionsInfo["Outfile"]))
Beispiel #8
0
def ProcessOptions():
    """Process and validate command line arguments and options"""
    
    MiscUtil.PrintInfo("Processing options...")
    
    # Validate options...
    ValidateOptions()
    
    OptionsInfo["Infile"] = Options["--infile"]
    OptionsInfo["InfileParams"] = MiscUtil.ProcessOptionInfileParameters("--infileParams", Options["--infileParams"], Options["--infile"])
    
    OptionsInfo["Outfile"] = Options["--outfile"]
    OptionsInfo["OutfileParams"] = MiscUtil.ProcessOptionOutfileParameters("--outfileParams", Options["--outfileParams"], Options["--infile"], Options["--outfile"])

    OptionsInfo["Overwrite"] = Options["--overwrite"]

    OptionsInfo["CountMode"] = False
    if re.match("^count$", Options["--mode"], re.I):
        OptionsInfo["CountMode"] = True
        
    OptionsInfo["MPMode"] = True if re.match("^yes$", Options["--mp"], re.I) else False
    OptionsInfo["MPParams"] = MiscUtil.ProcessOptionMultiprocessingParameters("--mpParams", Options["--mpParams"])

    SaltsByComponentsMode = False
    SaltsBySMARTSFileMode = False
    SaltsBySMARTSMode = False
    if re.match("^ByComponent$", Options["--saltsMode"], re.I):
        SaltsByComponentsMode = True
    elif re.match("^BySMARTSFile$", Options["--saltsMode"], re.I):
        SaltsBySMARTSFileMode = False
    elif re.match("^BySMARTS$", Options["--saltsMode"], re.I):
        SaltsBySMARTSMode = True
    else:
        MiscUtil.PrintError("The salts mode specified, %s, using \"--saltsMode\" option is not valid." % Options["--saltsMode"])
    OptionsInfo["SaltsByComponentsMode"]  = SaltsByComponentsMode
    OptionsInfo["SaltsBySMARTSFileMode"]  = SaltsBySMARTSFileMode
    OptionsInfo["SaltsBySMARTSMode"]  = SaltsBySMARTSMode

    SaltsFile = None
    if re.match("^BySMARTSFile$", Options["--saltsMode"], re.I):
        if not re.match("^auto$", Options["--saltsFile"], re.I):
            SaltsFile = Options["--saltsFile"]
    OptionsInfo["SaltsFile"] = SaltsFile
    
    SaltsSMARTS = None
    if re.match("^BySMARTS$", Options["--saltsMode"], re.I):
        if not Options["--saltsSMARTS"]:
            MiscUtil.PrintError("No salts SMARTS pattern specified using \"--saltsSMARTS\" option during \"BySMARTS\" value of \"-s, --saltsMode\" option")
        SaltsSMARTS = Options["--saltsSMARTS"].strip(" ")
        if not len(SaltsSMARTS):
            MiscUtil.PrintError("Empty SMARTS pattern specified using \"--saltsSMARTS\" option during \"BySMARTS\" value of \"-s, --saltsMode\" option")
        if re.search(" ", SaltsSMARTS):
            SaltsSMARTS = re.sub('[ ]+', '\n', SaltsSMARTS)
        
    OptionsInfo["SaltsSMARTS"] = SaltsSMARTS
Beispiel #9
0
def ProcessOptions():
    """Process and validate command line arguments and options"""

    MiscUtil.PrintInfo("Processing options...")

    # Validate options...
    ValidateOptions()

    OptionsInfo["CombineMatches"] = Options["--combineMatches"]

    OptionsInfo["CombineMatchResults"] = True
    if re.match("^No$", Options["--combineMatches"], re.I):
        OptionsInfo["CombineMatchResults"] = False
        if Options["--outfile"]:
            FileDir, FileName, FileExt = MiscUtil.ParseFileName(
                Options["--outfile"])
            OptionsInfo["OutfileBasename"] = FileName
            OptionsInfo["OutfileExt"] = FileExt

    OptionsInfo["CombineOperator"] = Options["--combineOperator"]
    OptionsInfo["AndCombineOperatorMode"] = True
    if re.match("^or$", Options["--combineOperator"], re.I):
        OptionsInfo["AndCombineOperatorMode"] = False

    OptionsInfo["GroupNamesFile"] = None
    if not re.match("^auto$", Options["--groupNamesFile"], re.I):
        OptionsInfo["GroupNamesFile"] = Options["--groupNamesFile"]

    OptionsInfo["FunctionalGroups"] = Options["--functionalGroups"]

    OptionsInfo["Infile"] = Options["--infile"]
    OptionsInfo["InfileParams"] = MiscUtil.ProcessOptionInfileParameters(
        "--infileParams", Options["--infileParams"], Options["--infile"])

    OptionsInfo["Outfile"] = Options["--outfile"]
    OptionsInfo["OutfileParams"] = MiscUtil.ProcessOptionOutfileParameters(
        "--outfileParams", Options["--outfileParams"], Options["--infile"],
        Options["--outfile"])

    OptionsInfo["Overwrite"] = Options["--overwrite"]

    OptionsInfo["CountMode"] = False
    if re.match("^count$", Options["--mode"], re.I):
        OptionsInfo["CountMode"] = True

    OptionsInfo["MPMode"] = True if re.match("^yes$", Options["--mp"],
                                             re.I) else False
    OptionsInfo["MPParams"] = MiscUtil.ProcessOptionMultiprocessingParameters(
        "--mpParams", Options["--mpParams"])

    OptionsInfo["UseChirality"] = False
    if re.match("^yes$", Options["--useChirality"], re.I):
        OptionsInfo["UseChirality"] = True
def ProcessOptions():
    """Process and validate command line arguments and options"""

    MiscUtil.PrintInfo("Processing options...")

    # Validate options...
    ValidateOptions()

    OptionsInfo["Autocorr2DExclude"] = True
    if not re.match("^Yes$", Options["--autocorr2DExclude"], re.I):
        OptionsInfo["Autocorr2DExclude"] = False

    OptionsInfo["FragmentCount"] = True
    if not re.match("^Yes$", Options["--fragmentCount"], re.I):
        OptionsInfo["FragmentCount"] = False

    OptionsInfo["DescriptorNames"] = Options["--descriptorNames"]
    OptionsInfo["Mode"] = Options["--mode"]

    OptionsInfo["Infile"] = Options["--infile"]
    OptionsInfo["InfileParams"] = MiscUtil.ProcessOptionInfileParameters(
        "--infileParams", Options["--infileParams"], Options["--infile"])

    OptionsInfo["Outfile"] = Options["--outfile"]
    OptionsInfo["OutfileParams"] = MiscUtil.ProcessOptionOutfileParameters(
        "--outfileParams", Options["--outfileParams"], Options["--infile"],
        Options["--outfile"])

    OptionsInfo["Overwrite"] = Options["--overwrite"]

    TextOutFileMode = False
    TextOutFileDelim = ""
    if MiscUtil.CheckFileExt(Options["--outfile"], "csv"):
        TextOutFileMode = True
        TextOutFileDelim = ","
    elif MiscUtil.CheckFileExt(Options["--outfile"], "tsv txt"):
        TextOutFileMode = True
        TextOutFileDelim = "\t"
    OptionsInfo["TextOutFileMode"] = TextOutFileMode
    OptionsInfo["TextOutFileDelim"] = TextOutFileDelim

    OptionsInfo["MPMode"] = True if re.match("^yes$", Options["--mp"],
                                             re.I) else False
    OptionsInfo["MPParams"] = MiscUtil.ProcessOptionMultiprocessingParameters(
        "--mpParams", Options["--mpParams"])

    OptionsInfo["Precision"] = int(Options["--precision"])

    OptionsInfo["SMILESOut"] = False
    if re.match("^Yes$", Options["--smilesOut"], re.I):
        OptionsInfo["SMILESOut"] = True
def ProcessOptions():
    """Process and validate command line arguments and options"""

    MiscUtil.PrintInfo("Processing options...")

    # Validate options...
    ValidateOptions()

    OptionsInfo["Infile"] = Options["--infile"]
    OptionsInfo["InfileParams"] = MiscUtil.ProcessOptionInfileParameters(
        "--infileParams", Options["--infileParams"], Options["--infile"])

    OptionsInfo["Outfile"] = Options["--outfile"]
    OptionsInfo["OutfileParams"] = MiscUtil.ProcessOptionOutfileParameters(
        "--outfileParams", Options["--outfileParams"])

    OptionsInfo["Overwrite"] = Options["--overwrite"]

    if re.match("^UFF$", Options["--forceField"], re.I):
        ForceField = "UFF"
        UseUFF = True
        UseMMFF = False
    elif re.match("^MMFF$", Options["--forceField"], re.I):
        ForceField = "MMFF"
        UseUFF = False
        UseMMFF = True
    else:
        MiscUtil.PrintError(
            "The value, %s, specified for \"--forceField\" is not supported." %
            (Options["--forceField"], ))

    MMFFVariant = "MMFF94" if re.match(
        "^MMFF94$", Options["--forceFieldMMFFVariant"], re.I) else "MMFF94s"

    OptionsInfo["ForceField"] = ForceField
    OptionsInfo["MMFFVariant"] = MMFFVariant
    OptionsInfo["UseMMFF"] = UseMMFF
    OptionsInfo["UseUFF"] = UseUFF

    if UseMMFF:
        OptionsInfo["EnergyLabel"] = "%s_Energy" % MMFFVariant
    else:
        OptionsInfo["EnergyLabel"] = "%s_Energy" % ForceField

    OptionsInfo["MPMode"] = True if re.match("^yes$", Options["--mp"],
                                             re.I) else False
    OptionsInfo["MPParams"] = MiscUtil.ProcessOptionMultiprocessingParameters(
        "--mpParams", Options["--mpParams"])

    OptionsInfo["QuietMode"] = True if re.match("^yes$", Options["--quiet"],
                                                re.I) else False
def ProcessOptions():
    """Process and validate command line arguments and options"""

    MiscUtil.PrintInfo("Processing options...")

    # Validate options...
    ValidateOptions()

    OptionsInfo["Infile"] = Options["--infile"]
    OptionsInfo["InfileParams"] = MiscUtil.ProcessOptionInfileParameters(
        "--infileParams", Options["--infileParams"], Options["--infile"])

    OptionsInfo["Outfile"] = Options["--outfile"]
    OptionsInfo["OutfileParams"] = MiscUtil.ProcessOptionOutfileParameters(
        "--outfileParams", Options["--outfileParams"], Options["--infile"],
        Options["--outfile"])

    OptionsInfo["Overwrite"] = Options["--overwrite"]

    OptionsInfo["Mode"] = Options["--mode"]
    OptionsInfo["UseGraphFrameworks"] = False
    if re.match("^GraphFrameworks$", OptionsInfo["Mode"], re.I):
        OptionsInfo["UseGraphFrameworks"] = True

    OptionsInfo["RemoveDuplicates"] = Options["--removeDuplicates"]
    OptionsInfo["RemoveDuplicateFrameworks"] = False
    if re.match("^Yes$", OptionsInfo["RemoveDuplicates"], re.I):
        OptionsInfo["RemoveDuplicateFrameworks"] = True

    # Setup outfile for writing out duplicates...
    OptionsInfo["DuplicatesOutfile"] = ""
    if OptionsInfo["RemoveDuplicateFrameworks"]:
        FileDir, FileName, FileExt = MiscUtil.ParseFileName(
            OptionsInfo["Outfile"])
        OptionsInfo["DuplicatesOutfile"] = "%sDuplicates.%s" % (FileName,
                                                                FileExt)

    OptionsInfo["Sort"] = Options["--sort"]
    OptionsInfo["SortFrameworks"] = False
    if re.match("^Yes$", OptionsInfo["Sort"], re.I):
        OptionsInfo["SortFrameworks"] = True

    OptionsInfo["SortOrder"] = Options["--sortOrder"]
    OptionsInfo["DescendingSortOrder"] = False
    if re.match("^Descending$", OptionsInfo["SortOrder"], re.I):
        OptionsInfo["DescendingSortOrder"] = True

    OptionsInfo["UseChirality"] = False
    if re.match("^yes$", Options["--useChirality"], re.I):
        OptionsInfo["UseChirality"] = True
Beispiel #13
0
def ProcessOptions():
    """Process and validate command line arguments and options"""
    
    MiscUtil.PrintInfo("Processing options...")
    
    # Validate options...
    ValidateOptions()
    
    # Process and setup options for RDKit functions...
    OptionsInfo["Infile"] = Options["--infile"]
    OptionsInfo["InfileParams"] = MiscUtil.ProcessOptionInfileParameters("--infileParams", Options["--infileParams"], Options["--infile"])
    
    OptionsInfo["Outfile"] = Options["--outfile"]
    OptionsInfo["OutfileParams"] = MiscUtil.ProcessOptionOutfileParameters("--outfileParams", Options["--outfileParams"], Options["--infile"], Options["--outfile"])
    
    OptionsInfo["Overwrite"] = Options["--overwrite"]
Beispiel #14
0
def ProcessOptions():
    """Process and validate command line arguments and options"""

    MiscUtil.PrintInfo("Processing options...")

    # Validate options...
    ValidateOptions()

    AllowParamFailure = True
    if re.match("^No", Options["--allowParamFailure"], re.I):
        AllowParamFailure = False
    OptionsInfo["AllowParamFailure"] = AllowParamFailure

    AtomAliasesFormatMode = True
    if re.match("^DataField", Options["--chargesSDFormat"], re.I):
        AtomAliasesFormatMode = False
    OptionsInfo["AtomAliasesFormatMode"] = AtomAliasesFormatMode

    OptionsInfo["DataFieldLabel"] = Options["--dataFieldLabel"]

    MMFFChargesMode = False
    if re.match("^MMFF", Options["--mode"], re.I):
        MMFFChargesMode = True
    OptionsInfo["Mode"] = Options["--mode"]
    OptionsInfo["MMFFChargesMode"] = MMFFChargesMode

    OptionsInfo["MPMode"] = True if re.match("^yes$", Options["--mp"],
                                             re.I) else False
    OptionsInfo["MPParams"] = MiscUtil.ProcessOptionMultiprocessingParameters(
        "--mpParams", Options["--mpParams"])

    OptionsInfo["Infile"] = Options["--infile"]
    OptionsInfo["InfileParams"] = MiscUtil.ProcessOptionInfileParameters(
        "--infileParams", Options["--infileParams"], Options["--infile"])

    OptionsInfo["Outfile"] = Options["--outfile"]
    OptionsInfo["OutfileParams"] = MiscUtil.ProcessOptionOutfileParameters(
        "--outfileParams", Options["--outfileParams"], Options["--infile"],
        Options["--outfile"])

    OptionsInfo["Overwrite"] = Options["--overwrite"]

    OptionsInfo["NumIters"] = int(Options["--numIters"])
    OptionsInfo["Precision"] = int(Options["--precision"])
def ProcessOptions():
    """Process and validate command line arguments and options"""

    MiscUtil.PrintInfo("Processing options...")

    # Validate options...
    ValidateOptions()

    OptionsInfo["Alignment"] = Options["--alignment"]

    OptionsInfo["UseRMSD"] = False
    OptionsInfo["UseBestRMSD"] = False

    OptionsInfo["UseOpen3A"] = False
    OptionsInfo["UseCrippenOpen3A"] = False

    # Process alignment
    if re.match("^RMSD$", OptionsInfo["Alignment"], re.I):
        OptionsInfo["UseRMSD"] = True
    elif re.match("^BestRMSD$", OptionsInfo["Alignment"], re.I):
        OptionsInfo["UseBestRMSD"] = True
    elif re.match("^Open3A$", OptionsInfo["Alignment"], re.I):
        OptionsInfo["UseOpen3A"] = True
    elif re.match("^CrippenOpen3A$", OptionsInfo["Alignment"], re.I):
        OptionsInfo["UseCrippenOpen3A"] = True

    OptionsInfo["MaxIters"] = int(Options["--maxIters"])

    OptionsInfo["Mode"] = Options["--mode"]

    OptionsInfo["RefFile"] = Options["--reffile"]
    OptionsInfo["ProbeFile"] = Options["--probefile"]

    # No need for any RDKit specific --outfileParams....
    OptionsInfo["InfileParams"] = MiscUtil.ProcessOptionInfileParameters(
        "--infileParams", Options["--infileParams"])

    OptionsInfo["Outfile"] = Options["--outfile"]
    OptionsInfo["OutfileParams"] = MiscUtil.ProcessOptionOutfileParameters(
        "--outfileParams", Options["--outfileParams"])

    OptionsInfo["Overwrite"] = Options["--overwrite"]
Beispiel #16
0
def ProcessOptions():
    """Process and validate command line arguments and options"""

    MiscUtil.PrintInfo("Processing options...")

    # Validate options...
    ValidateOptions()

    OptionsInfo["Infile"] = Options["--infile"]
    OptionsInfo["InfileParams"] = MiscUtil.ProcessOptionInfileParameters(
        "--infileParams", Options["--infileParams"], Options["--infile"])

    OptionsInfo["Outfile"] = Options["--outfile"]
    OptionsInfo["OutfileParams"] = MiscUtil.ProcessOptionOutfileParameters(
        "--outfileParams", Options["--outfileParams"])

    OptionsInfo["Overwrite"] = Options["--overwrite"]

    OptionsInfo["AddHydrogens"] = True
    if re.match("^no$", Options["--addHydrogens"], re.I):
        OptionsInfo["AddHydrogens"] = False

    OptionsInfo["AlignConformers"] = True
    if re.match("^no$", Options["--alignConformers"], re.I):
        OptionsInfo["AlignConformers"] = False

    if re.match("^ETDG$", Options["--conformerGenerator"], re.I):
        ConformerGenerator = "ETDG"
        UseExpTorsionAnglePrefs = True
        UseBasicKnowledge = False
    elif re.match("^KDG$", Options["--conformerGenerator"], re.I):
        ConformerGenerator = "KDG"
        UseExpTorsionAnglePrefs = False
        UseBasicKnowledge = True
    elif re.match("^ETKDG$", Options["--conformerGenerator"], re.I):
        ConformerGenerator = "ETKDG"
        UseExpTorsionAnglePrefs = True
        UseBasicKnowledge = True
    elif re.match("^SDG$", Options["--conformerGenerator"], re.I):
        ConformerGenerator = "SDG"
        UseExpTorsionAnglePrefs = False
        UseBasicKnowledge = False

    OptionsInfo["ConformerGenerator"] = ConformerGenerator
    OptionsInfo["UseExpTorsionAnglePrefs"] = UseExpTorsionAnglePrefs
    OptionsInfo["UseBasicKnowledge"] = UseBasicKnowledge

    if re.match("^UFF$", Options["--forceField"], re.I):
        ForceField = "UFF"
        UseUFF = True
        UseMMFF = False
        SkipForceFieldMinimization = False
    elif re.match("^MMFF$", Options["--forceField"], re.I):
        ForceField = "MMFF"
        UseUFF = False
        UseMMFF = True
        SkipForceFieldMinimization = False
    else:
        ForceField = "None"
        UseUFF = False
        UseMMFF = False
        SkipForceFieldMinimization = True

    MMFFVariant = "MMFF94" if re.match(
        "^MMFF94$", Options["--forceFieldMMFFVariant"], re.I) else "MMFF94s"

    OptionsInfo["SkipForceFieldMinimization"] = SkipForceFieldMinimization
    OptionsInfo["ForceField"] = ForceField
    OptionsInfo["MMFFVariant"] = MMFFVariant
    OptionsInfo["UseMMFF"] = UseMMFF
    OptionsInfo["UseUFF"] = UseUFF

    OptionsInfo["EnergyOut"] = True if re.match(
        "^yes$", Options["--energyOut"], re.I) else False
    if UseUFF:
        EnergyLabel = "UFF_Energy"
    elif UseMMFF:
        EnergyLabel = "%s_Energy" % MMFFVariant
    else:
        EnergyLabel = "Energy"
    OptionsInfo["EnergyLabel"] = EnergyLabel

    OptionsInfo["EnforceChirality"] = True
    if re.match("^no$", Options["--enforceChirality"], re.I):
        OptionsInfo["EnforceChirality"] = False

    OptionsInfo["EnergyWindow"] = float(Options["--energyWindow"])

    EmbedRMSDCutoff = -1.0
    if not re.match("^none$", Options["--embedRMSDCutoff"], re.I):
        EmbedRMSDCutoff = float(Options["--embedRMSDCutoff"])
    OptionsInfo["EmbedRMSDCutoff"] = EmbedRMSDCutoff

    EnergyRMSDCutoff = -1.0
    if not re.match("^none$", Options["--energyRMSDCutoff"], re.I):
        EnergyRMSDCutoff = float(Options["--energyRMSDCutoff"])
    OptionsInfo["EnergyRMSDCutoff"] = EnergyRMSDCutoff

    OptionsInfo["MaxIters"] = int(Options["--maxIters"])
    OptionsInfo["MaxConfs"] = Options["--maxConfs"]

    OptionsInfo["MPMode"] = True if re.match("^yes$", Options["--mp"],
                                             re.I) else False
    OptionsInfo["MPParams"] = MiscUtil.ProcessOptionMultiprocessingParameters(
        "--mpParams", Options["--mpParams"])

    OptionsInfo["QuietMode"] = True if re.match("^yes$", Options["--quiet"],
                                                re.I) else False

    RandomSeed = -1
    if not re.match("^auto$", Options["--randomSeed"], re.I):
        RandomSeed = int(Options["--randomSeed"])
    OptionsInfo["RandomSeed"] = RandomSeed

    OptionsInfo["RemoveHydrogens"] = True
    if re.match("^no$", Options["--removeHydrogens"], re.I):
        OptionsInfo["RemoveHydrogens"] = False
def ProcessOptions():
    """Process and validate command line arguments and options"""

    MiscUtil.PrintInfo("Processing options...")

    # Validate options...
    ValidateOptions()

    OptionsInfo["Infile"] = Options["--infile"]
    OptionsInfo["InfileParams"] = MiscUtil.ProcessOptionInfileParameters(
        "--infileParams", Options["--infileParams"], Options["--infile"])

    OptionsInfo["Outfile"] = Options["--outfile"]
    OptionsInfo["OutfileParams"] = MiscUtil.ProcessOptionOutfileParameters(
        "--outfileParams", Options["--outfileParams"])

    OptionsInfo["Overwrite"] = Options["--overwrite"]

    OptionsInfo["AddHydrogens"] = True
    if re.match("^no$", Options["--addHydrogens"], re.I):
        OptionsInfo["AddHydrogens"] = False

    if re.match("^ETDG$", Options["--conformerGenerator"], re.I):
        ConformerGenerator = "ETDG"
        UseExpTorsionAnglePrefs = True
        UseBasicKnowledge = False
        SkipConformerGeneration = False
    elif re.match("^KDG$", Options["--conformerGenerator"], re.I):
        ConformerGenerator = "KDG"
        UseExpTorsionAnglePrefs = False
        UseBasicKnowledge = True
        SkipConformerGeneration = False
    elif re.match("^ETKDG$", Options["--conformerGenerator"], re.I):
        ConformerGenerator = "ETKDG"
        UseExpTorsionAnglePrefs = True
        UseBasicKnowledge = True
        SkipConformerGeneration = False
    elif re.match("^SDG$", Options["--conformerGenerator"], re.I):
        ConformerGenerator = "SDG"
        UseExpTorsionAnglePrefs = False
        UseBasicKnowledge = False
        SkipConformerGeneration = False
    else:
        ConformerGenerator = "None"
        UseExpTorsionAnglePrefs = False
        UseBasicKnowledge = False
        SkipConformerGeneration = True

    OptionsInfo["SkipConformerGeneration"] = SkipConformerGeneration
    OptionsInfo["ConformerGenerator"] = ConformerGenerator
    OptionsInfo["UseExpTorsionAnglePrefs"] = UseExpTorsionAnglePrefs
    OptionsInfo["UseBasicKnowledge"] = UseBasicKnowledge

    if re.match("^UFF$", Options["--forceField"], re.I):
        ForceField = "UFF"
        UseUFF = True
        UseMMFF = False
    elif re.match("^MMFF$", Options["--forceField"], re.I):
        ForceField = "MMFF"
        UseUFF = False
        UseMMFF = True

    OptionsInfo["ForceField"] = ForceField
    OptionsInfo["UseMMFF"] = UseMMFF
    OptionsInfo["UseUFF"] = UseUFF

    OptionsInfo["EnforceChirality"] = True
    if re.match("^no$", Options["--enforceChirality"], re.I):
        OptionsInfo["EnforceChirality"] = False

    OptionsInfo["MaxIters"] = int(Options["--maxIters"])
    OptionsInfo["MaxConfs"] = int(Options["--maxConfs"])

    RandomSeed = -1
    if not re.match("^auto$", Options["--randomSeed"], re.I):
        RandomSeed = int(Options["--randomSeed"])
    OptionsInfo["RandomSeed"] = RandomSeed

    OptionsInfo["RemoveHydrogens"] = True
    if re.match("^no$", Options["--removeHydrogens"], re.I):
        OptionsInfo["RemoveHydrogens"] = False
def ProcessOptions():
    """Process and validate command line arguments and options"""
    
    MiscUtil.PrintInfo("Processing options...")
    
    # Validate options...
    ValidateOptions()
    
    OptionsInfo["ButinaSimilarityCutoff"] = float(Options["--butinaSimilarityCutoff"])
    OptionsInfo["ButinaReordering"] = False
    if re.match("^Yes$", Options["--butinaReordering"], re.I):
        OptionsInfo["ButinaReordering"] = True
    
    OptionsInfo["Fingerprints"] = Options["--fingerprints"]
    OptionsInfo["FingerprintsType"] = Options["--fingerprintsType"]
    
    OptionsInfo["ClusteringMethod"] = Options["--clusteringMethod"]
    ProcessClusteringMethodParameter()

    OptionsInfo["NumClusters"] = int(Options["--numClusters"])
    
    OptionsInfo["Infile"] = Options["--infile"]
    OptionsInfo["InfileParams"] = MiscUtil.ProcessOptionInfileParameters("--infileParams", Options["--infileParams"], Options["--infile"])
    
    OptionsInfo["Outfile"] = Options["--outfile"]
    OptionsInfo["OutfileParams"] = MiscUtil.ProcessOptionOutfileParameters("--outfileParams", Options["--outfileParams"], Options["--infile"], Options["--outfile"])
    
    OptionsInfo["Overwrite"] = Options["--overwrite"]

    OptionsInfo["OutFileMode"] = Options["--outfileMode"]
    SingleOutFileMode = True
    if not re.match("^SingleFile$", Options["--outfileMode"], re.I):
        SingleOutFileMode = False
    OptionsInfo["SingleOutFileMode"] = SingleOutFileMode
    
    FileDir, FileName, FileExt = MiscUtil.ParseFileName(Options["--outfile"])
    OptionsInfo["OutfileBasename"] = FileName
    OptionsInfo["OutfileExt"] = FileExt

    TextOutFileMode = False
    TextOutFileDelim = ""
    TextOutFileTitleLine = True
    
    if MiscUtil.CheckFileExt(Options["--outfile"], "csv"):
        TextOutFileMode = True
        TextOutFileDelim = ","
    elif MiscUtil.CheckFileExt(Options["--outfile"], "tsv txt"):
        TextOutFileMode = True
        TextOutFileDelim = "\t"
    elif MiscUtil.CheckFileExt(Options["--outfile"], "smi"):
        TextOutFileMode = True
        TextOutFileDelim = OptionsInfo["OutfileParams"]["SMILESDelimiter"]
        TextOutFileTitleLine = OptionsInfo["OutfileParams"]["SMILESTitleLine"]
        
    OptionsInfo["TextOutFileMode"] = TextOutFileMode
    OptionsInfo["TextOutFileDelim"] = TextOutFileDelim
    OptionsInfo["TextOutFileTitleLine"] = TextOutFileTitleLine
    
    OptionsInfo["SimilarityMetric"] = Options["--similarityMetric"]
    ProcessSimilarityMetricParameter()

    OptionsInfo["ParamsFingerprints"] = Options["--paramsFingerprints"]
    ProcessFingerprintsParameters()
def ProcessOptions():
    """Process and validate command line arguments and options"""

    MiscUtil.PrintInfo("Processing options...")

    # Validate options...
    ValidateOptions()

    OptionsInfo["CoreScaffold"] = Options["--coreScaffold"]

    OptionsInfo["Infile"] = Options["--infile"]
    OptionsInfo["InfileParams"] = MiscUtil.ProcessOptionInfileParameters(
        "--infileParams", Options["--infileParams"], Options["--infile"])

    OptionsInfo["Outfile"] = Options["--outfile"]
    OptionsInfo["OutfileParams"] = MiscUtil.ProcessOptionOutfileParameters(
        "--outfileParams", Options["--outfileParams"], Options["--infile"],
        Options["--outfile"])

    TextOutFileMode = False
    TextOutFileDelim = ""

    if MiscUtil.CheckFileExt(Options["--outfile"], "csv"):
        TextOutFileMode = True
        TextOutFileDelim = ","
    elif MiscUtil.CheckFileExt(Options["--outfile"], "tsv txt"):
        TextOutFileMode = True
        TextOutFileDelim = "\t"

    OptionsInfo["TextOutFileMode"] = TextOutFileMode
    OptionsInfo["TextOutFileDelim"] = TextOutFileDelim

    TextOutQuote = False
    if re.match("^auto$", Options["--quote"], re.I):
        if MiscUtil.CheckFileExt(Options["--outfile"], "csv"):
            TextOutQuote = True
    else:
        if re.match("^yes$", Options["--quote"], re.I):
            TextOutQuote = True
    OptionsInfo["TextOutQuote"] = TextOutQuote

    OptionsInfo["Overwrite"] = Options["--overwrite"]

    RemoveUnmatchedMode = False
    UnmatchedOutfile = None
    if re.match("^yes$", Options["--removeUnmatched"], re.I):
        RemoveUnmatchedMode = True
        FileDir, FileName, FileExt = MiscUtil.ParseFileName(
            OptionsInfo["Outfile"])
        UnmatchedOutfile = "%sUnmatched.%s" % (FileName, FileExt)
    OptionsInfo["RemoveUnmatchedMode"] = RemoveUnmatchedMode
    OptionsInfo["UnmatchedOutfile"] = UnmatchedOutfile

    OptionsInfo["SpecifiedDecompositionParams"] = Options[
        "--decompositionParams"]
    ProcessDecompositionParameters()

    OptionsInfo["SpecifiedMCSParams"] = Options["--mcsParams"]
    ProcessMCSParameters()

    SMARTSOrSMILESCoreScaffold = ""
    SMARTSOrSMILESCoreScaffoldList = []
    if not re.match("^none$", Options["--smartsOrSmilesCoreScaffold"],
                    re.I) or len(Options["--smartsOrSmilesCoreScaffold"]):
        if re.match("^(BySMARTS|BySMILES)$", Options["--coreScaffold"], re.I):
            SMARTSOrSMILESCoreScaffold = re.sub(
                " ", "", Options["--smartsOrSmilesCoreScaffold"])
            if not SMARTSOrSMILESCoreScaffold:
                MiscUtil.PrintError(
                    "A non empty value must be specified for \"-s, --smartsOrSmilesCoreScaffold\" during %s value of \"-c, --coreScaffold\" option "
                    % (Options["--coreScaffold"]))
            SMARTSOrSMILESCoreScaffoldList = SMARTSOrSMILESCoreScaffold.split(
                ",")
    OptionsInfo["SMARTSOrSMILESCoreScaffold"] = SMARTSOrSMILESCoreScaffold
    OptionsInfo[
        "SMARTSOrSMILESCoreScaffoldList"] = SMARTSOrSMILESCoreScaffoldList
def ProcessOptions():
    """Process and validate command line arguments and options"""
    
    MiscUtil.PrintInfo("Processing options...")
    
    # Validate options...
    ValidateOptions()
    
    OptionsInfo["Infile"] = Options["--infile"]
    OptionsInfo["InfileParams"] = MiscUtil.ProcessOptionInfileParameters("--infileParams", Options["--infileParams"], Options["--infile"])
    
    OptionsInfo["RefFile"] = Options["--reffile"]

    OptionsInfo["Scaffold"] = Options["--scaffold"]
    if re.match("^auto$", Options["--scaffold"], re.I):
        UseScaffoldMCS = True
        UseScaffoldSMARTS = False
        ScaffoldSMARTS = None
    else:
        UseScaffoldMCS = False
        UseScaffoldSMARTS = True
        ScaffoldSMARTS = OptionsInfo["Scaffold"]
    
    OptionsInfo["UseScaffoldMCS"] = UseScaffoldMCS
    OptionsInfo["UseScaffoldSMARTS"] = UseScaffoldSMARTS
    OptionsInfo["ScaffoldSMARTS"] = ScaffoldSMARTS
    OptionsInfo["ScaffoldPatternMol"] = None

    OptionsInfo["SpecifiedMCSParams"] = Options["--mcsParams"]
    ProcessMCSParameters()
    
    OptionsInfo["Outfile"] = Options["--outfile"]
    OptionsInfo["OutfileParams"] = MiscUtil.ProcessOptionOutfileParameters("--outfileParams", Options["--outfileParams"])
    
    OptionsInfo["Overwrite"] = Options["--overwrite"]

    OptionsInfo["AddHydrogens"] = True if re.match("^yes$", Options["--addHydrogens"], re.I) else False
    
    if re.match("^ETDG$", Options["--conformerGenerator"], re.I):
        ConformerGenerator = "ETDG"
        UseExpTorsionAnglePrefs = True
        UseBasicKnowledge = False
    elif re.match("^KDG$", Options["--conformerGenerator"], re.I):
        ConformerGenerator = "KDG"
        UseExpTorsionAnglePrefs = False
        UseBasicKnowledge = True
    elif re.match("^ETKDG$", Options["--conformerGenerator"], re.I):
        ConformerGenerator = "ETKDG"
        UseExpTorsionAnglePrefs = True
        UseBasicKnowledge = True
    elif re.match("^SDG$", Options["--conformerGenerator"], re.I):
        ConformerGenerator = "SDG"
        UseExpTorsionAnglePrefs = False
        UseBasicKnowledge = False
    else:
        MiscUtil.PrintError("The value, %s, specified for option \"-c, --conformerGenerator\" is not supported." % (Options["--conformerGenerator"]))
    
    OptionsInfo["ConformerGenerator"] = ConformerGenerator
    OptionsInfo["UseExpTorsionAnglePrefs"] = UseExpTorsionAnglePrefs
    OptionsInfo["UseBasicKnowledge"] = UseBasicKnowledge

    if re.match("^UFF$", Options["--forceField"], re.I):
        ForceField = "UFF"
        UseUFF = True
        UseMMFF = False
    elif re.match("^MMFF$", Options["--forceField"], re.I):
        ForceField = "MMFF"
        UseUFF = False
        UseMMFF = True
    else:
        MiscUtil.PrintError("The value, %s, specified for \"--forceField\" is not supported." % (Options["--forceField"],))
    
    MMFFVariant = "MMFF94" if re.match("^MMFF94$", Options["--forceFieldMMFFVariant"], re.I) else "MMFF94s"
    
    OptionsInfo["ForceField"] = ForceField
    OptionsInfo["MMFFVariant"] = MMFFVariant
    OptionsInfo["UseMMFF"] = UseMMFF
    OptionsInfo["UseUFF"] = UseUFF
    
    OptionsInfo["ScaffoldRMSDOut"] = True if re.match("^yes$", Options["--scaffoldRMSDOut"], re.I) else False
    
    OptionsInfo["EnergyOut"] = True if re.match("^yes$", Options["--energyOut"], re.I) else False
    if UseMMFF:
        OptionsInfo["EnergyLabel"] = "%s_Energy" % MMFFVariant
    else:
        OptionsInfo["EnergyLabel"] = "%s_Energy" % ForceField
    
    OptionsInfo["EnforceChirality"] = True if re.match("^yes$", Options["--enforceChirality"], re.I) else False
    
    OptionsInfo["MaxConfs"] = int(Options["--maxConfs"])
    
    OptionsInfo["MPMode"] = True if re.match("^yes$", Options["--mp"], re.I) else False
    OptionsInfo["MPParams"] = MiscUtil.ProcessOptionMultiprocessingParameters("--mpParams", Options["--mpParams"])
    
    OptionsInfo["QuietMode"] = True if re.match("^yes$", Options["--quiet"], re.I) else False
    
    OptionsInfo["RemoveHydrogens"] = True if re.match("^yes$", Options["--removeHydrogens"], re.I) else False
    OptionsInfo["UseTethers"] = True if re.match("^yes$", Options["--useTethers"], re.I) else False
Beispiel #21
0
def ProcessOptions():
    """Process and validate command line arguments and options"""

    MiscUtil.PrintInfo("Processing options...")

    # Validate options...
    ValidateOptions()

    Compute2DCoords = True
    if not re.match("^yes$", Options["--compute2DCoords"], re.I):
        Compute2DCoords = False
    OptionsInfo["Compute2DCoords"] = Compute2DCoords

    OptionsInfo["Mode"] = Options["--mode"]
    RxnByNameMode = True
    if not re.match("^RxnByName$", Options["--mode"], re.I):
        RxnByNameMode = False
    OptionsInfo["RxnByNameMode"] = RxnByNameMode

    OptionsInfo["ProdMolNamesMode"] = Options["--prodMolNames"]
    UseReactantNames = False
    if re.match("^UseReactants$", Options["--prodMolNames"], re.I):
        UseReactantNames = True
    OptionsInfo["UseReactantNames"] = UseReactantNames

    OptionsInfo["RxnName"] = Options["--rxnName"]
    OptionsInfo["RxnNameSMIRKS"] = None
    if OptionsInfo["RxnByNameMode"]:
        if not Options["--rxnName"]:
            MiscUtil.PrintError(
                "No rxn name specified using \"-r, --rxnName\" option during \"RxnByName\" value of \"-m, --mode\" option"
            )

    OptionsInfo["RxnNamesFile"] = None
    if not re.match("^auto$", Options["--rxnNamesFile"], re.I):
        OptionsInfo["RxnNamesFile"] = Options["--rxnNamesFile"]

    ReactantFiles = re.sub(" ", "", Options["--infiles"])
    ReactantFilesList = []
    ReactantFilesList = ReactantFiles.split(",")
    OptionsInfo["ReactantFiles"] = ReactantFiles
    OptionsInfo["ReactantFilesList"] = ReactantFilesList

    OptionsInfo["SpecifiedSMIRKS"] = Options["--smirksRxn"]
    if not OptionsInfo["RxnByNameMode"]:
        if not Options["--smirksRxn"]:
            MiscUtil.PrintError(
                "No rxn SMIRKS pattern specified using \"-r, --rxnName\" option during \"RxnByName\" value of \"-m, --mode\" option"
            )

    OptionsInfo["Outfile"] = Options["--outfile"]
    OptionsInfo["Overwrite"] = Options["--overwrite"]

    # Use first reactant file as input file as all input files have the same format...
    OptionsInfo["InfileParams"] = MiscUtil.ProcessOptionInfileParameters(
        "--infileParams", Options["--infileParams"], ReactantFilesList[0])

    # No need to pass any input or output file name due to absence of any auto parameter...
    OptionsInfo["OutfileParams"] = MiscUtil.ProcessOptionOutfileParameters(
        "--outfileParams", Options["--outfileParams"])

    Sanitize = True
    if not re.match("^yes$", Options["--sanitize"], re.I):
        Sanitize = False
    OptionsInfo["Sanitize"] = Sanitize
def ProcessOptions():
    """Process and validate command line arguments and options"""
    
    MiscUtil.PrintInfo("Processing options...")
    
    # Validate options...
    ValidateOptions()
    
    OptionsInfo["Infile"] = Options["--infile"]
    OptionsInfo["Outfile"] = Options["--outfile"]
    OptionsInfo["Overwrite"] = Options["--overwrite"]
    
    # No need for any RDKit specific --outfileParams....
    OptionsInfo["InfileParams"] = MiscUtil.ProcessOptionInfileParameters("--infileParams", Options["--infileParams"], OptionsInfo["Infile"])

    AlignmentSMARTSPattern = None
    if not re.match("^None$", Options["--alignmentSMARTS"], re.I):
        AlignmentSMARTSPattern = Options["--alignmentSMARTS"]
    OptionsInfo["AlignmentSMARTSPattern"]  = AlignmentSMARTSPattern
    
    OptionsInfo["AtomLabelFontSize"] = Options["--atomLabelFontSize"]
    OptionsInfo["BondLineWidth"] = Options["--bondLineWidth"]
    
    Compute2DCoords = True
    if re.match("^yes$", Options["--compute2DCoords"], re.I):
        Compute2DCoords = True
    elif re.match("^no$", Options["--compute2DCoords"], re.I):
        Compute2DCoords = False
    OptionsInfo["Compute2DCoords"]  = Compute2DCoords

    CounterCol = True
    if re.match("^no$", Options["--counterCol"], re.I):
        CounterCol = False
    OptionsInfo["CounterCol"]  = CounterCol
    
    ColVisibility = True
    if re.match("^no$", Options["--colVisibility"], re.I):
        ColVisibility = False
    OptionsInfo["ColVisibility"]  = ColVisibility
    
    OptionsInfo["FontBold"] = True
    if re.match("^no$", Options["--fontBold"], re.I):
        OptionsInfo["FontBold"] = False
        
    Footer = None
    if not re.match("^None$", Options["--footer"], re.I):
        Footer = Options["--footer"]
    OptionsInfo["Footer"]  = Footer

    FooterClass = Options["--footerClass"].strip()
    if MiscUtil.IsEmpty(FooterClass):
        MiscUtil.PrintError("The value specified using option \"--footerClass\" is empty.")
    OptionsInfo["FooterClass"]  = FooterClass
    
    Header = None
    if not re.match("^None$", Options["--header"], re.I):
        Header = Options["--header"]
    OptionsInfo["Header"]  = Header
    
    HeaderStyle = Options["--headerStyle"].strip()
    if MiscUtil.IsEmpty(HeaderStyle):
        MiscUtil.PrintError("The value specified using option \"--headerStyle\" is empty.")
    OptionsInfo["HeaderStyle"]  = HeaderStyle
    
    HighlightSMARTSPattern = None
    if not re.match("^None$", Options["--highlightSMARTS"], re.I):
        HighlightSMARTSPattern = Options["--highlightSMARTS"]
    OptionsInfo["HighlightSMARTSPattern"]  = HighlightSMARTSPattern
    
    OptionsInfo["Kekulize"] = True
    if re.match("^no$", Options["--kekulize"], re.I):
        OptionsInfo["Kekulize"] = False
        
    OptionsInfo["KeysNavigation"] = True
    if re.match("^no$", Options["--keysNavigation"], re.I):
        OptionsInfo["KeysNavigation"] = False
    
    SizeValues = Options["--molImageSize"].split(",")
    OptionsInfo["MolImageWidth"] = int(SizeValues[0])
    OptionsInfo["MolImageHeight"] = int(SizeValues[1])

    OptionsInfo["MolImageEncoded"] = True
    if re.match("^no$", Options["--molImageEncoded"], re.I):
        OptionsInfo["MolImageEncoded"] = False
    
    OptionsInfo["NumOfMolsPerRow"] = int(Options["--numOfMolsPerRow"])

    OptionsInfo["Paging"] = True
    if re.match("^no$", Options["--paging"], re.I):
        OptionsInfo["Paging"] = False
    
    PagingType = Options["--pagingType"]
    if not re.match("^(numbers|simple|simple_numbers|full|full_numbers|simple_number)$", Options["--pagingType"], re.I):
        MiscUtil.PrintWarning("The paging type name, %s, specified using option \"--pagingType\" appears to be a unknown type..." % (PagingType))
    OptionsInfo["PagingType"] = PagingType.lower()
    
    OptionsInfo["PageLength"] = int(Options["--pageLength"])
    
    OptionsInfo["Popover"] = True
    if re.match("^no$", Options["--popover"], re.I):
        OptionsInfo["Popover"] = False
    OptionsInfo["PopoverDataCount"] = int(Options["--popoverDataCount"])
    OptionsInfo["PopoverTextWidth"] = int(Options["--popoverTextWidth"])
    
    OptionsInfo["ShowMolName"] = True
    if re.match("^no$", Options["--showMolName"], re.I):
        OptionsInfo["ShowMolName"] = False
    
    OptionsInfo["ScrollX"] = True
    if re.match("^no$", Options["--scrollX"], re.I):
        OptionsInfo["ScrollX"] = False
        
    OptionsInfo["ScrollY"] = True
    if re.match("^no$", Options["--scrollY"], re.I):
        OptionsInfo["ScrollY"] = False

    OptionsInfo["ScrollYSize"] = Options["--scrollYSize"]
    if re.match("vh$", Options["--scrollYSize"], re.I):
        ScrollYSize = int(re.sub("vh$", "", Options["--scrollYSize"]))
        if ScrollYSize <= 0:
            MiscUtil.PrintError("The value specified, %s, for option \"--scrollYSize\" is not valid. Supported value: > 0 followed by \"vh\"" % Options["--scrollYSize"])
    
    TableStyle = None
    if not re.match("^None$", Options["--tableStyle"], re.I):
        if re.match("^All$", Options["--tableStyle"], re.I):
            TableStyle = "table table-striped table-bordered table-hover table-dark"
        else:
            TableStyle = re.sub(" ", "", Options["--tableStyle"])
            for Style in [Style for Style in TableStyle.split(",")]:
                if not re.match("^(table|table-striped|table-bordered|table-hover|table-dark|table-sm)$", Style, re.I):
                    MiscUtil.PrintWarning("The table style name, %s, specified using option \"-t, --tableStyle\" appears to be a unknown style..." % (Style))
            TableStyle = re.sub(",", " ", TableStyle.lower())
    OptionsInfo["TableStyle"]  = TableStyle

    OptionsInfo["TableFooter"] = True
    if re.match("^no$", Options["--tableFooter"], re.I):
        OptionsInfo["TableFooter"] = False
    
    OptionsInfo["TableHeader"] = True
    if re.match("^no$", Options["--tableHeader"], re.I):
        OptionsInfo["TableHeader"] = False
    
    TableHeaderStyle = None
    if not re.match("^None$", Options["--tableHeaderStyle"], re.I):
        TableHeaderStyle = Options["--tableHeaderStyle"]
        TableHeaderStyle = TableHeaderStyle.lower()
        CheckOptionTableClassColorValues("--tableHeaderStyle", [TableHeaderStyle])
    OptionsInfo["TableHeaderStyle"]  = TableHeaderStyle