Example #1
0
def processOneExcelFile(configPath, srcPath, scenario, destPath, isFirst):
    vJsonPath, eJsonPath, intentPath, entityMapPath, colorJsonPath = generateOutputPaths(
        destPath, scenario, isFirst)
    convertFile(configPath, srcPath, [], [scenario], [], vJsonPath, eJsonPath,
                intentPath, entityMapPath, colorJsonPath)

    return
Example #2
0
# Copyright (c) Microsoft Corporation.
# Licensed under the MIT license.
#-*- coding: utf-8 -*-

from ExcelReader import convertFile
from ExcelReader import generateOutputPaths
from ExcelReader import generateSimilarWordMap

if __name__ == "__main__":
    targetPath = "..\\..\\COVID19"

    vJsonPath, eJsonPath, intentPath, entityMapPath, colorJsonPath = generateOutputPaths(
        targetPath, "COVID19")

    excelPath = "..\\excel\\COVID19\\SmartKG_KGDesc_COVID19_zh.xlsx"

    similarWordMap = generateSimilarWordMap(
        "..\\excel\\COVID19\\similarWords_COVID19_zn.tsv")

    convertFile(excelPath, [], ["COVID19"], similarWordMap, vJsonPath,
                eJsonPath, intentPath, entityMapPath, True, colorJsonPath)
Example #3
0
# Copyright (c) Microsoft Corporation.
# Licensed under the MIT license.
#-*- coding: utf-8 -*-

from ExcelReader import convertFile
from ExcelReader import generateOutputPaths

default_rules = [
    "PhonicsGrade7\tPOSITIVE\t声|音调|传播", "MechanicsGrade7\tPOSITIVE\t力|运动|向量"
]

if __name__ == "__main__":
    targetPath = "..\\..\\Physics"

    vJsonPath, eJsonPath, intentPath, entityMapPath, colorJsonPath = generateOutputPaths(
        targetPath, "PhonicsGrade7")
    excelPath = "..\\excel\\Physics\\SmartKG_KGDesc_PhonicsGrade7_zh.xlsx"
    convertFile(excelPath, [], ["PhonicsGrade7"], [], vJsonPath, eJsonPath,
                intentPath, entityMapPath, colorJsonPath)

    vJsonPath, eJsonPath, intentPath, entityMapPath, colorJsonPath = generateOutputPaths(
        targetPath, "MechanicsGrade7")
    excelPath = "..\\excel\\Physics\\SmartKG_KGDesc_MechanicsGrade7_zh.xlsx"
    convertFile(excelPath, [], ["MechanicsGrade7"], [], vJsonPath, eJsonPath,
                intentPath, entityMapPath, colorJsonPath)
# Copyright (c) Microsoft Corporation.
# Licensed under the MIT license.

from ExcelReader import convertFile
from ExcelReader import generateOutputPaths


if __name__ == "__main__":
    targetPath = "..\\..\\COVID19_en"

    vJsonPath, eJsonPath, intentPath, entityMapPath, colorJsonPath = generateOutputPaths(targetPath, "COVID19_en")

    excelPath = "..\\excel\\COVID19\\SmartKG_KGDesc_COVID19_en.xlsx"

    convertFile(excelPath, [], ["COVID19_en"], [], vJsonPath, eJsonPath, intentPath, entityMapPath, True, colorJsonPath)
Example #5
0
# Copyright (c) Microsoft Corporation.
# Licensed under the MIT license.
#-*- coding: utf-8 -*-

from ExcelReader import convertFile
from ExcelReader import generateOutputPaths

default_rules = []

if __name__ == "__main__":
    targetPath = "..\\..\\Physics2"

    scenario = "MotionAndPower"

    vJsonPath, eJsonPath, intentPath, entityMapPath, colorJsonPath = generateOutputPaths(
        targetPath, scenario, True)
    excelPath = "..\\excel\\Physics2\\SmartKG_KGDesc_MotionAndPower_zh.xlsx"
    convertFile(excelPath, [], [scenario], [], vJsonPath, eJsonPath,
                intentPath, entityMapPath, colorJsonPath)

    scenario = "Phonics"

    vJsonPath, eJsonPath, intentPath, entityMapPath, colorJsonPath = generateOutputPaths(
        targetPath, scenario, False)
    excelPath = "..\\excel\\Physics\\SmartKG_KGDesc_PhonicsGrade7_zh.xlsx"
    convertFile(excelPath, [], [scenario], [], vJsonPath, eJsonPath,
                intentPath, entityMapPath, colorJsonPath)