Advertisement
alvations

Pywsd test

Jul 8th, 2015
376
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 4.73 KB | None | 0 0
  1. alvas@ubi:~/test$ git clone https://github.com/alvations/pywsd.git
  2. Cloning into 'pywsd'...
  3. remote: Counting objects: 1056, done.
  4. remote: Compressing objects: 100% (17/17), done.
  5. remote: Total 1056 (delta 8), reused 0 (delta 0), pack-reused 1039
  6. Receiving objects: 100% (1056/1056), 20.66 MiB | 936.00 KiB/s, done.
  7. Resolving deltas: 100% (745/745), done.
  8. Checking connectivity... done.
  9. alvas@ubi:~/test$ cd pywsd/
  10. alvas@ubi:~/test/pywsd$ python test_wsd.py
  11. ======== TESTING simple_lesk ===========
  12.  
  13. #TESTING simple_lesk() ...
  14. Context: I went to the bank to deposit my money
  15. Sense: Synset('deposit.v.02')
  16. Definition: put into a bank account
  17.  
  18. #TESTING simple_lesk() with POS ...
  19. Context: The river bank was full of dead fishes
  20. Sense: Synset('bank.n.01')
  21. Definition: sloping land (especially the slope beside a body of water)
  22.  
  23. #TESTING simple_lesk() with POS and stems ...
  24. Context: The workers at the industrial plant were overworked
  25. Sense: Synset('plant.n.04')
  26. Definition: something planted secretly for discovery by another
  27.  
  28. #TESTING simple_lesk() with nbest results
  29. Context: The workers at the industrial plant were overworked
  30. Senses ranked by #overlaps: [Synset('plant.n.04'), Synset('plant.n.03'), Synset('plant.n.02'), Synset('plant.n.01')]
  31. Definition: something planted secretly for discovery by another
  32.  
  33. #TESTING simple_lesk() with nbest results and scores
  34. Context: The workers at the industrial plant were overworked
  35. Senses ranked by #overlaps: [(1, Synset('plant.n.04')), (1, Synset('plant.n.03')), (1, Synset('plant.n.02')), (1, Synset('plant.n.01'))]
  36. Definition: something planted secretly for discovery by another
  37.  
  38. #TESTING simple_lesk() with nbest results and normalized scores
  39. Context: The workers at the industrial plant were overworked
  40. Senses ranked by #overlaps: [(0.25, Synset('plant.n.04')), (0.25, Synset('plant.n.03')), (0.25, Synset('plant.n.02')), (0.25, Synset('plant.n.01'))]
  41. Definition: something planted secretly for discovery by another
  42.  
  43. ======== TESTING adapted_lesk ===========
  44.  
  45. #TESTING adapted_lesk() ...
  46. Context: I went to the bank to deposit my money
  47. Sense: Synset('deposit.v.02')
  48. Definition: put into a bank account
  49.  
  50. #TESTING adapted_lesk() with pos, stem, nbest and scores.
  51. Context: I went to the bank to deposit my money
  52. Senses ranked by #overlaps: [(2, Synset('bank.n.09')), (1, Synset('savings_bank.n.02')), (1, Synset('depository_financial_institution.n.01')), (1, Synset('bank.n.10')), (1, Synset('bank.n.07')), (1, Synset('bank.n.06')), (1, Synset('bank.n.05')), (1, Synset('bank.n.04')), (1, Synset('bank.n.03')), (1, Synset('bank.n.01'))]
  53. Definition: a building in which the business of banking transacted
  54.  
  55. ======== TESTING cosine_lesk ===========
  56.  
  57. #TESTING cosine_lesk() ...
  58. Context: I went to the bank to deposit my money
  59. Sense: Synset('bank.v.05')
  60. Definition: be in the banking business
  61.  
  62. #TESTING cosine_lesk() with nbest results...
  63. Context: I went to the bank to deposit my money
  64. Senses ranked by #overlaps: [(Synset('bank.v.05'), 0.04598004898717029)]
  65. Definition: be in the banking business
  66.  
  67. ======== TESTING baseline ===========
  68.  
  69. #TESTING random_sense() ...
  70. Context: I went to the bank to deposit my money
  71. Sense: Synset('deposit.v.02')
  72. Definition: put into a bank account
  73.  
  74. #TESTING first_sense() ...
  75. Context: I went to the bank to deposit my money
  76. Sense: Synset('bank.n.01')
  77. Definition: sloping land (especially the slope beside a body of water)
  78.  
  79. #TESTING most_frequent_sense() ...
  80. Context: I went to the bank to deposit my money
  81. Sense: Synset('bank.n.01')
  82. Definition: sloping land (especially the slope beside a body of water)
  83.  
  84. ======== TESTING similarity ===========
  85.  
  86. Context: I went to the bank to deposit my money
  87. Similarity: path
  88. Sense: Synset('bank.n.09')
  89. Definition: a building in which the business of banking transacted
  90.  
  91. Context: I went to the bank to deposit my money
  92. Similarity: lch
  93. Sense: Synset('savings_bank.n.02')
  94. Definition: a container (usually with a slot in the top) for keeping money at home
  95.  
  96. Context: I went to the bank to deposit my money
  97. Similarity: wup
  98. Sense: Synset('bank.n.06')
  99. Definition: the funds held by a gambling house or the dealer in some gambling games
  100.  
  101. Context: I went to the bank to deposit my money
  102. Similarity: res
  103. Sense: Synset('depository_financial_institution.n.01')
  104. Definition: a financial institution that accepts deposits and channels the money into lending activities
  105.  
  106. Context: I went to the bank to deposit my money
  107. Similarity: jcn
  108. Sense: Synset('savings_bank.n.02')
  109. Definition: a container (usually with a slot in the top) for keeping money at home
  110.  
  111. Context: I went to the bank to deposit my money
  112. Similarity: lin
  113. Sense: Synset('savings_bank.n.02')
  114. Definition: a container (usually with a slot in the top) for keeping money at home
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement