Пример #1
0
def main():

    # ###uncomment for resume
    resume = openFile(
        'C:\\xampp\htdocs\CV-Parser-master\data\\input\\resume3.json')
    print(resume)
    resumeNode = ResumeNode("desmond", '97859875', '*****@*****.**', '456',
                            resume)

    ##uncomment for job desc
    content = openFile(
        'C:\\xampp\htdocs\CV-Parser-master\data\input\\jobdesc3.json')
    keywords = openFile(
        'C:\\xampp\htdocs\CV-Parser-master\data\input\keywords1.json')
    # print(resume)
    #
    jobNode = JobDescNode("545646", content, keywords)
    # print(personA.getImptKeywords())

    ResumeProcessor.construct(jobNode)
    ResumeProcessor.construct(resumeNode)

    imptKeywordSet = set(InformationNode.convertStringIntoList(keywords))
    print(imptKeywordSet)
    rskillSet = set(resumeNode.getSkills())
    jskillSet = set(jobNode.getSkills())
    resultSkillSet = rskillSet.intersection(jskillSet)
    resultSkillSet2 = rskillSet.intersection(imptKeywordSet)
    print(rskillSet)
    print(jskillSet)
    print(len(resultSkillSet) + len(resultSkillSet2))
    rLangSet = set(resumeNode.getLanguage())
    jLangSet = set(jobNode.getLanguage())
    resultLangSet = rLangSet.intersection(jLangSet)
    resultLangSet2 = rskillSet.intersection(imptKeywordSet)
    print(rLangSet)
    print(jLangSet)
    print(len(resultLangSet) + len(resultLangSet2))
    rLocationSet = resumeNode.getLocation().getCountry()
    jLocationSet = jobNode.getLocation().getCountry()
    resultLocationSet = int(rLocationSet == jLocationSet)
    print(resultLocationSet)
    print(rLocationSet)
    print(jLocationSet)

    print(resumeNode.getEducation())
    print(jobNode.getEducation())
    print(
        compareEducationBetweenJobandResume(resumeNode.getEducation(),
                                            jobNode.getEducation()))
    print(
        compareExperienceBetweenJobandResume(
            resumeNode.getExperience(), jobNode.getExperience(),
            InformationNode.convertStringIntoList(keywords)))
Пример #2
0
def main():

    # ###uncomment for resume
    resume = openFile("C:\\xampp\htdocs\CV-Parser-master\data\\input\\resume3.json")
    print(resume)
    resumeNode = ResumeNode("desmond", "97859875", "*****@*****.**", "456", resume)

    ##uncomment for job desc
    content = openFile("C:\\xampp\htdocs\CV-Parser-master\data\input\\jobdesc3.json")
    keywords = openFile("C:\\xampp\htdocs\CV-Parser-master\data\input\keywords1.json")
    # print(resume)
    #
    jobNode = JobDescNode("545646", content, keywords)
    # print(personA.getImptKeywords())

    ResumeProcessor.construct(jobNode)
    ResumeProcessor.construct(resumeNode)

    imptKeywordSet = set(InformationNode.convertStringIntoList(keywords))
    print(imptKeywordSet)
    rskillSet = set(resumeNode.getSkills())
    jskillSet = set(jobNode.getSkills())
    resultSkillSet = rskillSet.intersection(jskillSet)
    resultSkillSet2 = rskillSet.intersection(imptKeywordSet)
    print(rskillSet)
    print(jskillSet)
    print(len(resultSkillSet) + len(resultSkillSet2))
    rLangSet = set(resumeNode.getLanguage())
    jLangSet = set(jobNode.getLanguage())
    resultLangSet = rLangSet.intersection(jLangSet)
    resultLangSet2 = rskillSet.intersection(imptKeywordSet)
    print(rLangSet)
    print(jLangSet)
    print(len(resultLangSet) + len(resultLangSet2))
    rLocationSet = resumeNode.getLocation().getCountry()
    jLocationSet = jobNode.getLocation().getCountry()
    resultLocationSet = int(rLocationSet == jLocationSet)
    print(resultLocationSet)
    print(rLocationSet)
    print(jLocationSet)

    print(resumeNode.getEducation())
    print(jobNode.getEducation())
    print(compareEducationBetweenJobandResume(resumeNode.getEducation(), jobNode.getEducation()))
    print(
        compareExperienceBetweenJobandResume(
            resumeNode.getExperience(), jobNode.getExperience(), InformationNode.convertStringIntoList(keywords)
        )
    )
Пример #3
0
def main():

    # ###uncomment for resume
    resume = openFile('C:\\xampp\htdocs\CV-Parser-master\data\input\\1.json')
    print(resume)
    personA = ResumeNode("mike", '97859875', '*****@*****.**', '456',
                         resume)

    ##uncomment for job desc
    # resume = openFile('C:\\xampp\htdocs\CV-Parser-master\data\input\\jobdesc3.json')
    # keywords = openFile('C:\\xampp\htdocs\CV-Parser-master\data\\keywords.json')
    #print(resume)

    # personA = JobDescNode("545646", resume, keywords)
    # print(personA.getImptKeywords())

    ResumeProcessor.construct(personA)
    print("----- SKILLS -----")
    print(personA.getSkills())
    print("----- Education -----")
    print(personA.getEducation())
    print("----- Language -----")
    print(personA.getLanguage())
    print("----- Experience -----")
    print(personA.getExperience())
    for i in personA.getExperience():
        print(i.workPositionOrExp)
        print(i.workDuration)
    print("----- Location -----")
    print(personA.getLocation())
    print(personA.getLocation().getAddress())
    print(personA.getLocation().getCountry())
    print(personA.getLocation().getCity())

    #### FOR PRINTING OUT THE LINES IN CONTENT
    # for i, j in enumerate(InformationNode.convertStringIntoList(personA.getContent())):
    #     print('------------------------------- ',i)
    #     print(j)

    # temp = CustomClassJson.encodeClassToJson(personA)
    # with open('sampleJob2.json', 'w') as outfile:
    #     json.dump(temp, outfile)

    tester1 = CustomClassJson.encodeClassToJson(personA)
    print(tester1)
Пример #4
0
def main():

    # ###uncomment for resume
    resume = openFile('C:\\xampp\htdocs\CV-Parser-master\data\input\\1.json')
    print(resume)
    personA = ResumeNode("mike", '97859875', '*****@*****.**', '456', resume)

    ##uncomment for job desc
    # resume = openFile('C:\\xampp\htdocs\CV-Parser-master\data\input\\jobdesc3.json')
    # keywords = openFile('C:\\xampp\htdocs\CV-Parser-master\data\\keywords.json')
    #print(resume)

    # personA = JobDescNode("545646", resume, keywords)
    # print(personA.getImptKeywords())

    ResumeProcessor.construct(personA)
    print("----- SKILLS -----")
    print(personA.getSkills())
    print("----- Education -----")
    print(personA.getEducation())
    print("----- Language -----")
    print(personA.getLanguage())
    print("----- Experience -----")
    print(personA.getExperience())
    for i in personA.getExperience():
        print(i.workPositionOrExp)
        print(i.workDuration)
    print("----- Location -----")
    print(personA.getLocation())
    print(personA.getLocation().getAddress())
    print(personA.getLocation().getCountry())
    print(personA.getLocation().getCity())

    #### FOR PRINTING OUT THE LINES IN CONTENT
    # for i, j in enumerate(InformationNode.convertStringIntoList(personA.getContent())):
    #     print('------------------------------- ',i)
    #     print(j)

    # temp = CustomClassJson.encodeClassToJson(personA)
    # with open('sampleJob2.json', 'w') as outfile:
    #     json.dump(temp, outfile)

    tester1 = CustomClassJson.encodeClassToJson(personA)
    print(tester1)