In a previous question I posted in Stackoverflow, I asked about Pyrouge installation. After receiving the answer, I applied it. From the pypi installation steps, I did
pip install pyrouge
Then (here is where I substituted the pypi original step 2,
pyrouge_set_rouge_path.py /absolute/path/to/ROUGE-1.5.5/directory
with the answer I received from stackoverflow):
set pyrouge_set_rouge_path=C:\rouge
Then, I ran the following command to make sure it installed correctly:
python -m pyrouge.test
I was supposed to receive the following output:
Ran 10 tests in 3.753s
OK
But instead got the following output:
Ran 10 tests in 0.034s
FAILED (erros=10)
Above that I received an Error for every test attempt.
Error1: test_config_file (pyrouge.tests.Rouge155_test.PyrougeTest)
Error2: test_convert_summaries (pyrouge.tests.Rouge155_test.PyrougeTest)
Error3: test_evaluation (pyrouge.tests.Rouge155_test.PyrougeTest)
Error4: test_options (pyrouge.tests.Rouge155_test.PyrougeTest)
Error5: test_paths (pyrouge.tests.Rouge155_test.PyrougeTest)
Error6: test_rouge_for_plain_text (pyrouge.tests.Rouge155_test.PyrougeTest)
Error7: test_text_conversion (pyrouge.tests.Rouge155_test.PyrougeTest)
Error8: test_write_config (pyrouge.tests.Rouge155_test.PyrougeTest)
Error9: test_wrong_model_pattern (pyrouge.tests.Rouge155_test.PyrougeTest)
Error10: test_wrong_system_pattern (pyrouge.tests.Rouge155_test.PyrougeTest)
The following are the detailed first and last errors:
First Error: """
EEEEEEEEEE
======================================================================
ERROR: test_config_file (pyrouge.tests.Rouge155_test.PyrougeTest)
----------------------------------------------------------------------
Traceback (most recent call last):
File "C:\Python27\lib\site-packages\pyrouge\tests\Rouge155_test.py", line 138,
in test_config_file
rouge = Rouge155()
File "C:\Python27\lib\site-packages\pyrouge\Rouge155.py", line 88, in __init__
self.__set_rouge_dir(rouge_dir)
File "C:\Python27\lib\site-packages\pyrouge\Rouge155.py", line 402, in __set_r
ouge_dir
self._home_dir = self.__get_rouge_home_dir_from_settings()
File "C:\Python27\lib\site-packages\pyrouge\Rouge155.py", line 416, in __get_r
ouge_home_dir_from_settings
with open(self._settings_file) as f:
IOError: [Errno 2] No such file or directory: u'C:\\Users\\IQ\\AppData\\Roaming\
\pyrouge\\settings.ini'
"""
Last Error: """
ERROR: test_wrong_system_pattern (pyrouge.tests.Rouge155_test.PyrougeTest)
----------------------------------------------------------------------
Traceback (most recent call last):
File "C:\Python27\lib\site-packages\pyrouge\tests\Rouge155_test.py", line 59,
in test_wrong_system_pattern
rouge = Rouge155()
File "C:\Python27\lib\site-packages\pyrouge\Rouge155.py", line 88, in __init__
self.__set_rouge_dir(rouge_dir)
File "C:\Python27\lib\site-packages\pyrouge\Rouge155.py", line 402, in __set_r
ouge_dir
self._home_dir = self.__get_rouge_home_dir_from_settings()
File "C:\Python27\lib\site-packages\pyrouge\Rouge155.py", line 416, in __get_r
ouge_home_dir_from_settings
with open(self._settings_file) as f:
IOError: [Errno 2] No such file or directory: u'C:\\Users\\IQ\\AppData\\Roaming\
\pyrouge\\settings.ini'
"""
I have opened the directory: C:\Users\IQ\AppData\Roaming\pyrouge\, but it was empty. I would like to know what it is that is wrong, and how to fix it.
Thank you.
You should first install ROUGE-1.5.5 by following this tutorial. Only the two commands to install and no configuration is needed. Keep in mind to generate the wordnet bd file. by running
Under the data directory.
Then install the pyrouge from source. Remember to comment out the print lines which will trigger errors.
Then all will just goes fine.