Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't locate XML/Parser.pm in @INC #18

Closed
minji-o-j opened this issue Aug 10, 2023 · 1 comment
Closed

Can't locate XML/Parser.pm in @INC #18

minji-o-j opened this issue Aug 10, 2023 · 1 comment

Comments

@minji-o-j
Copy link

File "/workspace/TextBox/textbox/utils/dashboard.py", line 316, in new_experiment
yield True
File "/workspace/TextBox/textbox/quick_start/experiment.py", line 129, in run
self._do_train_and_valid()
File "/workspace/TextBox/textbox/quick_start/experiment.py", line 107, in _do_train_and_valid
self.valid_result = self.trainer.fit(train_data, valid_data)
File "/workspace/TextBox/textbox/trainer/trainer.py", line 431, in fit
self.stopped |= self._valid(valid_data, "epoch")
File "/opt/conda/lib/python3.9/site-packages/torch/autograd/grad_mode.py", line 27, in decorate_context
return func(*args, **kwargs)
File "/workspace/TextBox/textbox/trainer/trainer.py", line 275, in _valid
valid_results = self.evaluate(valid_data, is_valid=True)
File "/opt/conda/lib/python3.9/site-packages/torch/autograd/grad_mode.py", line 27, in decorate_context
return func(*args, **kwargs)
File "/workspace/TextBox/textbox/trainer/trainer.py", line 536, in evaluate
result = self.evaluator.evaluate(generate_corpus, reference_dataset)
File "/workspace/TextBox/textbox/evaluator/base_evaluator.py", line 167, in evaluate
metric_result = evaluator.evaluate(generate_corpus, reference_corpus, avg=avg)
File "/workspace/TextBox/textbox/evaluator/abstract_evaluator.py", line 31, in evaluate
metric_dict = self._calc_metrics_info(generate_corpus=generate_corpus, reference_corpus=reference_corpus)
File "/workspace/TextBox/textbox/evaluator/rouge_evaluator.py", line 56, in _calc_metrics_info
output = r.convert_and_evaluate(rouge_args=rouge_args_str)
File "/opt/conda/lib/python3.9/site-packages/pyrouge/Rouge155.py", line 368, in convert_and_evaluate
rouge_output = self.evaluate(system_id, rouge_args)
File "/opt/conda/lib/python3.9/site-packages/pyrouge/Rouge155.py", line 343, in evaluate
rouge_output = check_output(command, env=env).decode("UTF-8")
File "/opt/conda/lib/python3.9/subprocess.py", line 424, in check_output
return run(*popenargs, stdout=PIPE, timeout=timeout, check=True,
File "/opt/conda/lib/python3.9/subprocess.py", line 528, in run
raise CalledProcessError(retcode, process.args,
subprocess.CalledProcessError: Command '['/workspace/.files2rouge/ROUGE-1.5.5.pl', '-e', '/workspace/.files2rouge/data', '-c', '95', '-r', '1000', '-n', '2', '-w', '1.2', '-a', '-m', '/tmp/tmplgzej6tx/rouge_conf.xml']' returned non-zero exit status 2.

Can't locate XML/Parser.pm in @inc (you may need to install the XML::Parser module) (@inc contains: /workspace/.files2rouge /etc/perl /usr/local/lib/x86_64-linux-gnu/perl/5.26.1 /usr/local/share/perl/5.26.1 /usr/lib/x86_64-linux-gnu/perl5/5.26 /usr/share/perl5 /usr/lib/x86_64-linux-gnu/perl/5.26 /usr/share/perl/5.26 /usr/local/lib/site_perl /usr/lib/x86_64-linux-gnu/perl-base) at /workspace/.files2rouge/XML/DOM.pm line 41.
BEGIN failed--compilation aborted at /workspace/.files2rouge/XML/DOM.pm line 70.
Compilation failed in require at /workspace/.files2rouge/ROUGE-1.5.5.pl line 177.
BEGIN failed--compilation aborted at /workspace/.files2rouge/ROUGE-1.5.5.pl line 177.

@minji-o-j
Copy link
Author

bheinzerling/pyrouge#27

apt-get install libxml-parser-perl

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant