Giter VIP home page Giter VIP logo

Comments (9)

hbq1 avatar hbq1 commented on June 29, 2024 1

Ah I see, it all makes sense now, TY!

@broper2 are you interested in preparing the fix?

from chex.

broper2 avatar broper2 commented on June 29, 2024

Hi, I would like to work on this issue if no one else has picked it up. Thanks!

from chex.

hbq1 avatar hbq1 commented on June 29, 2024

Hi @fvisin, thanks for opening this issue.
And thanks for volunteering @broper2!

static_argnames kwarg is not supported in the original pmap because of in_axes incompatibility with kwargs (see the docstring). I would prefer not to add this to chex to avoid possible confusion / problems with forward compatibility. WDYT?

Re: checking **_unused_kwargs -- that's exactly what's accomplished by @check_variant_arguments :)

from chex.

fvisin avatar fvisin commented on June 29, 2024

that's exactly what's accomplished by @check_variant_arguments :)

...how did I miss that!? Apologies for the noise 🤦

static_argnames kwarg is not supported in the original pmap because of in_axes incompatibility with kwargs (see the docstring). I would prefer not to add this to chex to avoid possible confusion / problems with forward compatibility. WDYT?

That makes sense. Do you think it would be reasonable to fail with a more specific error message when static_argnames is set, though? It took me a while to realise that the argument was being ignored, it would have helped to know that a possible reason for the test failing was that static_argnames is ignored by with_pmap.

from chex.

hbq1 avatar hbq1 commented on June 29, 2024

That's a good point! We can prohibit users from using both static_argnames and static_argnums at the same time in variants' args, wdyt?

from chex.

fvisin avatar fvisin commented on June 29, 2024

That's also a good idea, but I don't think it would have solved my specific case!

I was setting only static_argnames, but since with_pmap was ignoring it I didn't immediately realise why the test was failing. When static_argnames is set and with_pmap fails, it would be handy if the error message suggested that the failure might be caused by static_argnames being ignored by with_pmap due to it not being supported in the original pmap. Does it make sense?

from chex.

broper2 avatar broper2 commented on June 29, 2024

Thanks @hbq1, will get this PR up within the week.

from chex.

broper2 avatar broper2 commented on June 29, 2024

Hi @hbq1, dont want to leave you hanging...but I have had some other stuff come up. May be best to have someone else take this issue and prepare the PR.

from chex.

hbq1 avatar hbq1 commented on June 29, 2024

NP, thanks for letting me know @broper2!

from chex.

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.