Code Monkey home page Code Monkey logo

Comments (10)

MatthieuDartiailh avatar MatthieuDartiailh commented on July 20, 2024

As usual it would be best to have @sccolbert opinion on this but I believe that you should try to avoid building over-large systems. Typically enaml use one solver per container to keep the system size reasonable. In your case it sounds like you could break the problem in multiple pieces which is likely to give better results.

I never had time to look at your implementation but I still hope to do so at one point now that I spent sometime in enaml codebase to write the documentation.

from kiwi.

jklymak avatar jklymak commented on July 20, 2024

@MatthieuDartiailh Thanks! My implementation probably needs another set of eyes. Its seems pretty robust for most conditions, but maybe there are serious design flaws... I've not used a constraints system before, so probably made a bunch of mistakes.

In this case, I understand what you are suggesting about nesting the solvers, but I'm not sure that's practical. Basically, in the horizontal, everything I'm specifying needs to be part of the constraints. A good number of constraints are redundant given the grid layout (i.e. the left edge of each axes in a column is the same, and if the axes span the same number of columns, their widths are the same) so perhaps there is room for optimization there. But that would make the code a lot more complicated.

from kiwi.

MatthieuDartiailh avatar MatthieuDartiailh commented on July 20, 2024

It is by no means perfect but you can have a look at my description pf enaml system in kiwi docs. I agree the code may end up beong more convoluted (enaml is), but it may be the price. My plate is quite full at the moment but I will try to have a look next week or the week after. Don't hesitate to ping me if you do not hear from me.

from kiwi.

sccolbert avatar sccolbert commented on July 20, 2024

from kiwi.

sccolbert avatar sccolbert commented on July 20, 2024

from kiwi.

jklymak avatar jklymak commented on July 20, 2024

Thanks @sccolbert Not sure I can really do that since in this iteration the width of some objects depends on the height, and neither are known.

A related question: I have a few "helper" Variables with constraints like axlb.width == axlb.right - axlb.left | 'required'. These could all be removed, but would that help the solution be more manageable?

from kiwi.

sccolbert avatar sccolbert commented on July 20, 2024

from kiwi.

sccolbert avatar sccolbert commented on July 20, 2024

from kiwi.

MatthieuDartiailh avatar MatthieuDartiailh commented on July 20, 2024

@jklymak I belive you fixed your issue now in matplotlib correct ? Would you mind providing a quick conclusion to this issue ?

from kiwi.

jklymak avatar jklymak commented on July 20, 2024

Not directly - I did a rewrite that had far fewer constraints. Always goes better the second time around ;-). OTOH I don't think the new system will take into account ratios, so this can certainly be closed.

from kiwi.

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.