|
PLearn 0.1
|
#include "wn.h"#include <plearn/base/general.h>#include <plearn_learners/language/Bitext/ShellProgressBar.h>#include "Set.h"

Go to the source code of this file.
Classes | |
| struct | PLearn::Node |
| class | PLearn::WordNetOntology |
Namespaces | |
| namespace | PLearn |
< for swap | |
Defines | |
| #define | NOUN_TYPE 1 |
| #define | VERB_TYPE 2 |
| #define | ADJ_TYPE 3 |
| #define | ADV_TYPE 4 |
| #define | ADJ_SATELLITE_TYPE 5 |
| #define | ALL_WN_TYPE 6 |
| #define | UNDEFINED_TYPE 7 |
| #define | NUMERIC_TYPE 8 |
| #define | PROPER_NOUN_TYPE 9 |
| #define | SYNSETTAG_ID -2 |
| #define | UNDEFINED_SS_ID -1 |
| #define | ROOT_SS_ID 0 |
| #define | SUPER_UNKNOWN_SS_ID 1 |
| #define | NOUN_SS_ID 2 |
| #define | VERB_SS_ID 3 |
| #define | ADJ_SS_ID 4 |
| #define | ADV_SS_ID 5 |
| #define | OOV_SS_ID 6 |
| #define | PROPER_NOUN_SS_ID 7 |
| #define | NUMERIC_SS_ID 8 |
| #define | PUNCTUATION_SS_ID 9 |
| #define | STOP_SS_ID 10 |
| #define | BOS_SS_ID 11 |
| #define | EOS_SS_ID 12 |
| #define | UNDEFINED_OFFSET -1 |
| #define | ROOT_OFFSET -2 |
| #define | SUPER_UNKNOWN_OFFSET -3 |
| #define | NOUN_OFFSET -4 |
| #define | VERB_OFFSET -5 |
| #define | ADJ_OFFSET -6 |
| #define | ADV_OFFSET -7 |
| #define | OOV_OFFSET -8 |
| #define | PROPER_NOUN_OFFSET -9 |
| #define | NUMERIC_OFFSET -10 |
| #define | PUNCTUATION_OFFSET -11 |
| #define | STOP_OFFSET -12 |
| #define | BOS_OFFSET -13 |
| #define | EOS_OFFSET -14 |
| #define | SUPER_FNUM -1 |
| #define | NULL_TAG "<null>" |
| #define | OOV_TAG "<oov>" |
| #define | PROPER_NOUN_TAG "<proper_noun>" |
| #define | NUMERIC_TAG "<numeric>" |
| #define | PUNCTUATION_TAG "<punctuation>" |
| #define | STOP_TAG "<stop>" |
| #define | BOS_TAG "<s>" |
| #define | EOS_TAG "</s>" |
| #define | VERB_TAG "<verb>" |
| #define | NOUN_TAG "<noun>" |
| #define | ADJ_TAG "<adj>" |
| #define | ADV_TAG "<adv>" |
| #define | UNDEFINED_TAG "<undefined>" |
| #define | WNO_ERROR -1000 |
| #define | WORD_COVERAGE_THRESHOLD 10 |
Functions | |
| string | PLearn::trimWord (string word) |
| string | PLearn::stemWord (string &word) |
| string | PLearn::stemWord (string &word, int wn_pos) |
| bool | PLearn::isLetter (char c) |
| bool | PLearn::isDigit (char c) |
| bool | PLearn::isAlpha (char c) |
| bool | PLearn::isLegalPunct (char c) |
| char * | PLearn::cstr (string &str) |
| Takes a string and returns a char array of that string. | |
| void | PLearn::removeDelimiters (string &s, string delim, string replace) |
| bool | PLearn::startsWith (string &base, string s) |
| void | PLearn::replaceChars (string &str, string char_to_replace, string replacing_char) |
| #define ADJ_OFFSET -6 |
Definition at line 90 of file WordNetOntology.h.
Referenced by PLearn::WordNetOntology::createBaseSynsets().
| #define ADJ_SATELLITE_TYPE 5 |
Definition at line 62 of file WordNetOntology.h.
| #define ADJ_SS_ID 4 |
Definition at line 75 of file WordNetOntology.h.
Referenced by PLearn::WordNetOntology::createBaseSynsets(), PLearn::WordNetOntology::extractWordHighLevelSenses(), PLearn::WordNetOntology::isTopLevelCategory(), and PLearn::WordNetOntology::linkUpperCategories().
| #define ADJ_TAG "<adj>" |
Definition at line 114 of file WordNetOntology.h.
| #define ADJ_TYPE 3 |
Definition at line 60 of file WordNetOntology.h.
Referenced by convertPOS2WNO(), PLearn::WordNetOntology::extractSenses(), PLearn::WordNetOntology::extractWord(), PLearn::WordNetOntology::getPredominentSyntacticClassForWord(), PLearn::WordNetOntology::getWordSenseIdForWnsn(), PLearn::WordNetOntology::hasSenseInWordNet(), PLearn::WordNetOntology::isInWordNet(), PLearn::WordNetOntology::linkUpperCategories(), PLearn::WordNetOntology::load(), PLearn::TextSenseSequenceVMatrix::permute(), and PLearn::GraphicalBiText::test_WSD().
| #define ADV_OFFSET -7 |
Definition at line 91 of file WordNetOntology.h.
Referenced by PLearn::WordNetOntology::createBaseSynsets().
| #define ADV_SS_ID 5 |
Definition at line 76 of file WordNetOntology.h.
Referenced by PLearn::WordNetOntology::createBaseSynsets(), PLearn::WordNetOntology::extractWordHighLevelSenses(), PLearn::WordNetOntology::isTopLevelCategory(), and PLearn::WordNetOntology::linkUpperCategories().
| #define ADV_TAG "<adv>" |
Definition at line 115 of file WordNetOntology.h.
| #define ADV_TYPE 4 |
Definition at line 61 of file WordNetOntology.h.
Referenced by convertPOS2WNO(), PLearn::WordNetOntology::extractSenses(), PLearn::WordNetOntology::extractWord(), PLearn::WordNetOntology::getPredominentSyntacticClassForWord(), PLearn::WordNetOntology::getWordSenseIdForWnsn(), PLearn::WordNetOntology::hasSenseInWordNet(), PLearn::WordNetOntology::isInWordNet(), PLearn::WordNetOntology::linkUpperCategories(), PLearn::WordNetOntology::load(), PLearn::TextSenseSequenceVMatrix::permute(), and PLearn::GraphicalBiText::test_WSD().
| #define ALL_WN_TYPE 6 |
Definition at line 63 of file WordNetOntology.h.
Referenced by PLearn::WordNetOntology::extractWord(), and main().
| #define BOS_OFFSET -13 |
Definition at line 97 of file WordNetOntology.h.
Referenced by PLearn::WordNetOntology::createBaseSynsets().
| #define BOS_SS_ID 11 |
Definition at line 82 of file WordNetOntology.h.
Referenced by PLearn::WordNetOntology::catchSpecialTags(), PLearn::WordNetOntology::createBaseSynsets(), and PLearn::WordNetOntology::isTopLevelCategory().
| #define BOS_TAG "<s>" |
Definition at line 109 of file WordNetOntology.h.
Referenced by PLearn::WordNetOntology::catchSpecialTags(), and main().
| #define EOS_OFFSET -14 |
Definition at line 98 of file WordNetOntology.h.
Referenced by PLearn::WordNetOntology::createBaseSynsets(), and PLearn::WordNetOntology::processUnknownWord().
| #define EOS_SS_ID 12 |
Definition at line 83 of file WordNetOntology.h.
Referenced by PLearn::WordNetOntology::catchSpecialTags(), PLearn::WordNetOntology::createBaseSynsets(), PLearn::WordNetOntology::init(), and PLearn::WordNetOntology::isTopLevelCategory().
| #define EOS_TAG "</s>" |
Definition at line 110 of file WordNetOntology.h.
Referenced by PLearn::WordNetOntology::catchSpecialTags(), and main().
| #define NOUN_OFFSET -4 |
Definition at line 88 of file WordNetOntology.h.
Referenced by PLearn::WordNetOntology::createBaseSynsets().
| #define NOUN_SS_ID 2 |
Definition at line 73 of file WordNetOntology.h.
Referenced by PLearn::WordNetOntology::createBaseSynsets(), PLearn::WordNetOntology::extractWordHighLevelSenses(), PLearn::WordNetOntology::extractWordNounAndVerbHighLevelSenses(), PLearn::WordNetOntology::isTopLevelCategory(), and PLearn::WordNetOntology::linkUpperCategories().
| #define NOUN_TAG "<noun>" |
Definition at line 113 of file WordNetOntology.h.
| #define NOUN_TYPE 1 |
Definition at line 58 of file WordNetOntology.h.
Referenced by convertPOS2WNO(), PLearn::WordNetOntology::extractSenses(), PLearn::WordNetOntology::extractWord(), PLearn::WordNetOntology::getPredominentSyntacticClassForWord(), PLearn::WordNetOntology::getWordSenseIdForWnsn(), PLearn::WordNetOntology::hasSenseInWordNet(), PLearn::GraphicalBiText::init(), PLearn::GraphicalBiText::init_WSD(), PLearn::WordNetOntology::isInWordNet(), PLearn::WordNetOntology::linkUpperCategories(), PLearn::WordNetOntology::load(), PLearn::TextSenseSequenceVMatrix::permute(), and PLearn::GraphicalBiText::test_WSD().
| #define NULL_TAG "<null>" |
Definition at line 102 of file WordNetOntology.h.
Referenced by PLearn::WordNetOntology::extractWord(), PLearn::WordNetOntology::getWord(), PLearn::WordNetOntology::isInWordNet(), and PLearn::trimWord().
| #define NUMERIC_OFFSET -10 |
Definition at line 94 of file WordNetOntology.h.
Referenced by PLearn::WordNetOntology::createBaseSynsets().
| #define NUMERIC_SS_ID 8 |
Definition at line 79 of file WordNetOntology.h.
Referenced by PLearn::WordNetOntology::catchSpecialTags(), PLearn::WordNetOntology::createBaseSynsets(), PLearn::WordNetOntology::isTopLevelCategory(), and PLearn::WordNetOntology::lookForSpecialTags().
| #define NUMERIC_TAG "<numeric>" |
Definition at line 106 of file WordNetOntology.h.
Referenced by PLearn::WordNetOntology::catchSpecialTags(), and main().
| #define NUMERIC_TYPE 8 |
Definition at line 65 of file WordNetOntology.h.
Referenced by main().
| #define OOV_OFFSET -8 |
Definition at line 92 of file WordNetOntology.h.
Referenced by PLearn::WordNetOntology::createBaseSynsets().
| #define OOV_SS_ID 6 |
Definition at line 77 of file WordNetOntology.h.
Referenced by PLearn::WordNetOntology::catchSpecialTags(), PLearn::WordNetOntology::createBaseSynsets(), PLearn::WordNetOntology::isTopLevelCategory(), and PLearn::WordNetOntology::lookForSpecialTags().
| #define OOV_TAG "<oov>" |
Definition at line 104 of file WordNetOntology.h.
Referenced by PLearn::GraphicalBiText::build_(), PLearn::WordNetOntology::catchSpecialTags(), PLearn::ReIndexedTargetVMatrix::getNewRow(), PLearn::WordNetOntology::getWordId(), PLearn::GraphicalBiText::init(), PLearn::GraphicalBiText::init_WSD(), PLearn::GraphicalBiText::loadBitext(), main(), and PLearn::GraphicalBiText::test_WSD().
| #define PROPER_NOUN_OFFSET -9 |
Definition at line 93 of file WordNetOntology.h.
Referenced by PLearn::WordNetOntology::createBaseSynsets().
| #define PROPER_NOUN_SS_ID 7 |
Definition at line 78 of file WordNetOntology.h.
Referenced by PLearn::WordNetOntology::catchSpecialTags(), PLearn::WordNetOntology::createBaseSynsets(), PLearn::WordNetOntology::isTopLevelCategory(), and PLearn::WordNetOntology::lookForSpecialTags().
| #define PROPER_NOUN_TAG "<proper_noun>" |
Definition at line 105 of file WordNetOntology.h.
Referenced by PLearn::WordNetOntology::catchSpecialTags(), and main().
| #define PROPER_NOUN_TYPE 9 |
Definition at line 66 of file WordNetOntology.h.
Referenced by main().
| #define PUNCTUATION_OFFSET -11 |
Definition at line 95 of file WordNetOntology.h.
Referenced by PLearn::WordNetOntology::createBaseSynsets().
| #define PUNCTUATION_SS_ID 9 |
Definition at line 80 of file WordNetOntology.h.
Referenced by PLearn::WordNetOntology::catchSpecialTags(), PLearn::WordNetOntology::createBaseSynsets(), PLearn::WordNetOntology::isTopLevelCategory(), and PLearn::WordNetOntology::lookForSpecialTags().
| #define PUNCTUATION_TAG "<punctuation>" |
Definition at line 107 of file WordNetOntology.h.
Referenced by PLearn::WordNetOntology::catchSpecialTags(), and main().
| #define ROOT_OFFSET -2 |
Definition at line 86 of file WordNetOntology.h.
Referenced by PLearn::WordNetOntology::createBaseSynsets().
| #define ROOT_SS_ID 0 |
Definition at line 71 of file WordNetOntology.h.
Referenced by PLearn::GraphicalBiText::compute_node_level(), PLearn::GraphicalBiText::compute_nodemap(), PLearn::GraphicalBiText::compute_pMC(), PLearn::WordNetOntology::createBaseSynsets(), PLearn::WordNetOntology::getRootSynset(), PLearn::WordNetOntology::isTopLevelCategory(), PLearn::WordNetOntology::linkUpperCategories(), and PLearn::GraphicalBiText::printHierarchy().
| #define STOP_OFFSET -12 |
Definition at line 96 of file WordNetOntology.h.
Referenced by PLearn::WordNetOntology::createBaseSynsets().
| #define STOP_SS_ID 10 |
Definition at line 81 of file WordNetOntology.h.
Referenced by PLearn::WordNetOntology::catchSpecialTags(), PLearn::WordNetOntology::createBaseSynsets(), PLearn::WordNetOntology::isTopLevelCategory(), and PLearn::WordNetOntology::lookForSpecialTags().
| #define STOP_TAG "<stop>" |
Definition at line 108 of file WordNetOntology.h.
Referenced by PLearn::WordNetOntology::catchSpecialTags().
| #define SUPER_FNUM -1 |
Definition at line 100 of file WordNetOntology.h.
Referenced by PLearn::Node::Node().
| #define SUPER_UNKNOWN_OFFSET -3 |
Definition at line 87 of file WordNetOntology.h.
Referenced by PLearn::WordNetOntology::createBaseSynsets().
| #define SUPER_UNKNOWN_SS_ID 1 |
Definition at line 72 of file WordNetOntology.h.
Referenced by PLearn::WordNetOntology::createBaseSynsets(), PLearn::WordNetOntology::extractWordHighLevelSenses(), PLearn::WordNetOntology::isTopLevelCategory(), and PLearn::WordNetOntology::processUnknownWord().
| #define SYNSETTAG_ID -2 |
Definition at line 68 of file WordNetOntology.h.
Referenced by PLearn::TextSenseSequenceVMatrix::getNewRow(), and PLearn::TextSenseSequenceVMatrix::getRestrictedRow().
| #define UNDEFINED_OFFSET -1 |
Definition at line 85 of file WordNetOntology.h.
| #define UNDEFINED_SS_ID -1 |
| #define UNDEFINED_TAG "<undefined>" |
Definition at line 116 of file WordNetOntology.h.
| #define UNDEFINED_TYPE 7 |
Definition at line 64 of file WordNetOntology.h.
Referenced by PLearn::TextSenseSequenceVMatrix::apply_boundary(), convertPOS2WNO(), PLearn::WordNetOntology::createBaseSynsets(), PLearn::TextSenseSequenceVMatrix::getNewRow(), PLearn::WordNetOntology::getPredominentSyntacticClassForWord(), PLearn::TextSenseSequenceVMatrix::getRestrictedRow(), PLearn::TextSenseSequenceVMatrix::permute(), PLearn::WordNetOntology::processUnknownWord(), and PLearn::GraphicalBiText::test_WSD().
| #define VERB_OFFSET -5 |
Definition at line 89 of file WordNetOntology.h.
Referenced by PLearn::WordNetOntology::createBaseSynsets().
| #define VERB_SS_ID 3 |
Definition at line 74 of file WordNetOntology.h.
Referenced by PLearn::WordNetOntology::createBaseSynsets(), PLearn::WordNetOntology::extractWordHighLevelSenses(), PLearn::WordNetOntology::extractWordNounAndVerbHighLevelSenses(), PLearn::WordNetOntology::isTopLevelCategory(), and PLearn::WordNetOntology::linkUpperCategories().
| #define VERB_TAG "<verb>" |
Definition at line 112 of file WordNetOntology.h.
| #define VERB_TYPE 2 |
Definition at line 59 of file WordNetOntology.h.
Referenced by convertPOS2WNO(), PLearn::WordNetOntology::extractSenses(), PLearn::WordNetOntology::extractWord(), PLearn::WordNetOntology::getPredominentSyntacticClassForWord(), PLearn::WordNetOntology::getWordSenseIdForWnsn(), PLearn::WordNetOntology::hasSenseInWordNet(), PLearn::WordNetOntology::isInWordNet(), PLearn::WordNetOntology::linkUpperCategories(), PLearn::WordNetOntology::load(), PLearn::TextSenseSequenceVMatrix::permute(), and PLearn::GraphicalBiText::test_WSD().
| #define WNO_ERROR -1000 |
Definition at line 118 of file WordNetOntology.h.
Referenced by PLearn::WordNetOntology::getWordSenseIdForSenseKey(), PLearn::WordNetOntology::getWordSenseIdForWnsn(), and main().
| #define WORD_COVERAGE_THRESHOLD 10 |
Definition at line 120 of file WordNetOntology.h.
Referenced by PLearn::WordNetOntology::printSynsetAncestors(), and PLearn::WordNetOntology::printWordAncestors().
1.7.4