Skip to content

Multithreaded Computation or slow CPU #6

Open
@TheDammedSon

Description

@TheDammedSon

Hi,

I'm really like this approach to the problem.

The thing is when I use big sets of small rolls (typically around 70 units) it's freezes.
My question is my computer slow ( i5-4460 with 8 Gb of RAM) or is this computation single-threaded?

How can I work is around?

Thank you in advance

Activity

emadehsan

emadehsan commented on Aug 15, 2021

@emadehsan
Owner

Hi @TheDammedSon,

This code is actually expansion of Serge Kruk's code: cutting_stock.py, the code accompanying his book Practical Python AI Projects. Which is meant for learning rather than production usage.

In Optimization Problems like Cutting Stock Problem, the time to solve the problem (as well as problem space) increases exponentially with the increase in input size.

I think your machine is good. This implementation is not optimized for higher inputs or multi-threads.

The work around is to either use some production ready Cutting Stock Solver or learn OR-Tools and optimize this Cutting Stock Solver.

Helpful links:

emadehsan

emadehsan commented on Aug 15, 2021

@emadehsan
Owner

@TheDammedSon if you successfully increase the speed of this algorithm, please feel free to create a Pull request.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

      Development

      No branches or pull requests

        Participants

        @emadehsan@TheDammedSon

        Issue actions

          Multithreaded Computation or slow CPU · Issue #6 · emadehsan/csp