Code Monkey home page Code Monkey logo

Comments (5)

rgerkin avatar rgerkin commented on September 4, 2024

@russelljjarvis
This is supposed to be taken care of automatically by the fact that (at least in scidash/dev) all core types now inherit from sciunit.SciUnit, which creates an unpicklable attribute in its constructor. If this is working, then why do we also need a picklable attribute as well? Shouldn't everything that is not unpicklable be picklable?

from neuronunit.

russelljjarvis avatar russelljjarvis commented on September 4, 2024

Sorry yes, it was supposed to read:

if not hasattr(score,'unpicklable'):
     score.unpicklable = []

I must have been tired when writing it.

I can confirm that the lines:

class SciUnit(object):
    """Abstract base class for models, tests, and scores."""
    def __init__(self):
        self.unpicklable = [] # Attributes that cannot or should n

are still in sciunit, note that this seems to satisfy all of the tests in the suite besides class RheobaseTest(VmTest), which is the only test to contain score type of scores.RatioScore. I am unsure why it fails for scores.RatioScore but not the other score types. Looking into this now.

from neuronunit.

rgerkin avatar rgerkin commented on September 4, 2024

I think if I add unpicklable = [] as an attribute to the SciUnit class, not just create it in the constructor, then any subclass instance should have that attribute even if somehow the constructor never got called. I think the constructor isn't getting called because you are somehow putting instances of tests into test suites with attributes that were not fully realized by the usual route.

from neuronunit.

rgerkin avatar rgerkin commented on September 4, 2024

Done in scidash/sciunit@e6f7009. Check to see if this works for you know, @russelljjarvis.

from neuronunit.

rgerkin avatar rgerkin commented on September 4, 2024

I think this is fixed or obsolete with the new Backend implementation.

from neuronunit.

Related Issues (20)

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.