Giter Site home page Giter Site logo

Comments (6)

peteanderson80 avatar peteanderson80 commented on August 20, 2024 1

Hi,

I haven't seen this before. The problem is originating from the LMDB database that is used to cache parsed reference captions. This is purely for speeding up repeated evaluations, so you can disable it. To do this, just delete the line '-cache', cache_dir, at /pycocoevalcap/spice/spice.py:64. Evaluations will be slower but it will definitely avoid this error.

To fix the problem, I had a quick look at the LMDB docs, but there is no further information about this error or how to resolve it. I'm not an LMDB expert so it might take a bit of digging around in the LMDB code to understand the cause.

from coco-caption.

rasoolfa avatar rasoolfa commented on August 20, 2024

Hi
Thanks for your response.
Yes, it caused by cache. I did a similar thing but in a different way as you mentioned that to delete the cache after every single run. With this trick, it works. But I guess deleting that line would be a better way to deal with this. Thanks again.

from coco-caption.

AtharvTalnikar avatar AtharvTalnikar commented on August 20, 2024

Hi!
I am having issues implementing SPICE.Please help

Error: Could not score batched file input:
java.lang.ClassCastException: org.json.simple.JSONArray cannot be cast to java.lang.String
at edu.anu.spice.SpiceScorer.scoreBatch(SpiceScorer.java:95)
at edu.anu.spice.SpiceScorer.main(SpiceScorer.java:60)
Traceback (most recent call last):
File "/content/pycocoevalcap/spice/model_evaluation.py", line 238, in
Val_with_MLE()
File "/content/pycocoevalcap/spice/model_evaluation.py", line 236, in Val_with_MLE
spice_class.compute_score(all_usable_ref,all_gen_sents)
File "/content/pycocoevalcap/spice/test.py", line 78, in compute_score
cwd=os.path.dirname(os.path.abspath(file)))
File "/usr/lib/python3.6/subprocess.py", line 311, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['java', '-jar', '-Xmx8G', 'spice-1.0.jar', '/content/pycocoevalcap/spice/tmp/tmpr49ny2ll', '-cache', '/content/pycocoevalcap/spice/cache', '-out', '/content/pycocoevalcap/spice/tmp/tmpl8edcdti', '-subset', '-silent']' returned non-zero exit status 1.

from coco-caption.

Robertwyq avatar Robertwyq commented on August 20, 2024

I meet this problem too, how do you fix it

from coco-caption.

WangLanxiao avatar WangLanxiao commented on August 20, 2024

I meet this problem too, how do you fix it

from coco-caption.

HenryHZY avatar HenryHZY commented on August 20, 2024

I have also met this problem "Error: Could not score batched file input". I cannot fix it apart from re-installing the whole environment. That is really confused.

from coco-caption.

Related Issues (6)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.