Giter Club home page Giter Club logo

Comments (23)

moschd avatar moschd commented on August 16, 2024 1

@Westlife1002 Because each new item that is being evaluated to be placed inside the bin is being checked against all items already placed in the bin in order to determine if it is a valid position. This makes calculation time far from linear. For example, see the loop at line 148 in main.py.

from 3d-bin-packing.

moschd avatar moschd commented on August 16, 2024 1

@Westlife1002 Hi, yes this is very true. Feel free to contact me on [email protected].

from 3d-bin-packing.

jerry800416 avatar jerry800416 commented on August 16, 2024

use Python 3.6 & pip install -r requirenments.txt

from 3d-bin-packing.

Westlife1002 avatar Westlife1002 commented on August 16, 2024

I am using Python 3.6.5. still got this issue

from 3d-bin-packing.

jerry800416 avatar jerry800416 commented on August 16, 2024

I can't reproduce this error, can you provide me the version number of the installed package and the OS used?

from 3d-bin-packing.

Westlife1002 avatar Westlife1002 commented on August 16, 2024

I am using windows 10, Python 3.6.5. from above error log it's something wrong in main.py, specifically "_plotCylinder". I can run example 1-4 without any problem. for example 5 I think it's ploting Cylinder and this issue happened.

from 3d-bin-packing.

jerry800416 avatar jerry800416 commented on August 16, 2024

I'm sorry that i can't reproduce this error, maybe you can provide more info .
In my guess,the problem is with the matplotlib version,fc is the attribute in matplotlib 3.3.4, check your matplotlib version and re-execute.
Let me know if this solves your problem ,tks

from 3d-bin-packing.

Westlife1002 avatar Westlife1002 commented on August 16, 2024

I checked, it's Version: 2.2.3. is this version not working well? I cannot upgrade it because of other version dependency. Could you please take a look at plotly 3D mesh library which produce nicer interactive 3D graph: https://plotly.com/python/3d-mesh/#mesh-cube If you can add such ploting capability of it that will be greate.

from 3d-bin-packing.

Westlife1002 avatar Westlife1002 commented on August 16, 2024

Another question, in your version of 3DBP, is the distribution function disabled? i.e. can we still input multiple boxes or containers to pack all items? it seems this version can only support one bin/container to calculate.

from 3d-bin-packing.

jerry800416 avatar jerry800416 commented on August 16, 2024

I checked, it's Version: 2.2.3. is this version not working well? I cannot upgrade it because of other version dependency. Could you please take a look at plotly 3D mesh library which produce nicer interactive 3D graph: https://plotly.com/python/3d-mesh/#mesh-cube If you can add such ploting capability of it that will be greate.

There is currently no plan to add a new plot library, maybe you can try to use virtualenv to solve the matplotlib version problem.

from 3d-bin-packing.

Westlife1002 avatar Westlife1002 commented on August 16, 2024

OK, I will try. I have one more question. Does the model really consider how to put cylindar items with other cube items seriously, to ensure the way of loading them are realistically sensible? e.g. avoiding putting cube items on top of the cylindar items because it will fall down during transport. I saw in the main.py that only the drawing part distinguish the cylindar and cube items, which seems that before this procedure all items are actually treated as cube item for calculating the result? Please clarify this issue or any potential limitations in real business practice. thank you very much

from 3d-bin-packing.

jerry800416 avatar jerry800416 commented on August 16, 2024

The upside-down setting of the cylinder item is invalid, so no scrolling issues will occur, because packer will ensure that the upside is flat, you can check main.py -- line 29 self.updown = updown if typeof == ' cube' else False.

Cylinder items use the diameter as W and H, so it is essentially the same as a cube, but note that W must be equal to H when adding a cylinder.
ex. packer.addItem(Item(partno='Box-5' , name='test', typeof='cylinder', WHD=(1,1 , 5), weight=1, level=1,loadbear=100, updown=True, color='olive'))

from 3d-bin-packing.

Westlife1002 avatar Westlife1002 commented on August 16, 2024

so you mean the cylinder item can only be put upright and they cannot be laid down(lay flat)?

from 3d-bin-packing.

jerry800416 avatar jerry800416 commented on August 16, 2024

In my case ,yes.

from 3d-bin-packing.

Westlife1002 avatar Westlife1002 commented on August 16, 2024

where can I remove the limitation? I prefer the model to determin if the cylinder item should be put upright or laid down. and if possible, how to add the constraint that any cube item cannot be put on top of a cylinder item. this will fit for majority of the scenario in real practice.

from 3d-bin-packing.

jerry800416 avatar jerry800416 commented on August 16, 2024

Sorry,there is no way to remove the limitation.
The cylinder only be upright, so the drawing function doesn't consider the situation of upside down.If the limitation is removed, it will cause an error in the drawing function.

from 3d-bin-packing.

Westlife1002 avatar Westlife1002 commented on August 16, 2024

Why does this model take so much time to compute a solution when the quanity of items is big. e.g. I have 3 types of boxes loading for a 40' container:

65*33*26 (252 cartons); 
84*42*33 (222 cartons);
 48*48*38 (270 cartons); 

it took nearly 10 minutes to reach a solution. why does it become dramatically slower when the number of items (boxes) increased?

from 3d-bin-packing.

Westlife1002 avatar Westlife1002 commented on August 16, 2024

@Westlife1002 Because each new item that is being evaluated to be placed inside the bin is being checked against all items already placed in the bin in order to determine if it is a valid position. This makes calculation time far from linear. For example, see the loop at line 148 in main.py.

do u have any workaround on this issue? apparently the computing time is too slow to be useful in this case.

from 3d-bin-packing.

moschd avatar moschd commented on August 16, 2024

There are definitely ways to improve calculation time, but incorporating these concepts into the current implementation are not rudimentary. I sadly will not have the spare time to contribute to this repository. If you are interested in an implementation that can support fast-paced high-volume logistic operations, you can let me know how to contact you and I might be able to help you.

from 3d-bin-packing.

Westlife1002 avatar Westlife1002 commented on August 16, 2024

@moschd hi Moshchd, this is very import issue, as in real world a lot of shipments come with small cartons to fill a container. Please let me know how to contact you. thank you for your help.
@jerry800416 do you have any quick workaround? thanks

from 3d-bin-packing.

jerry800416 avatar jerry800416 commented on August 16, 2024

@Westlife1002 If you need fast calculation, you need use algorithms such as GA , PSO or neural network. This is my goal to improve in the next stage, but I have not completed it yet , and it's not a free public project.
If @moschd can help you, please contact him.

from 3d-bin-packing.

allenxu avatar allenxu commented on August 16, 2024

Hi Jerry ,
I know it's closed, but I got some question here.

If we apply WHD to xyz, and cylinder can only be put in a upright manner. I think the diameter of cylinder should be W and D? I know it's working correctly in current version , where W and H stand for diameter. I still got this question, could you point out what's wrong with my thoughts? And if you think it's more convenient you can use Chinese cause I am from mainland.

Thanks

from 3d-bin-packing.

jerry800416 avatar jerry800416 commented on August 16, 2024

Hi @allenxu :
如果直徑設置為W和D,那確實是可以讓圓柱體以傾倒的狀態打包,但是如果開放這個功能,則會有更多的延伸問題,比如說

  1. 圓柱體傾倒放置後,因頂部非平面,那是否可以在上面堆疊物品?
  2. 圓柱體傾倒放置後,是否有滾動的可能,那在圓柱體滾動的情況下,如何確保堆疊在上面的物品不會因此產生翻覆的狀況?

所以我傾向於在完善上述規則前,僅開放圓柱體以直立式打包

另外,目前圓柱體打包方式實際上還是和立方體一樣的模式,兩者的差別只在畫圖上而已,後續可優化的方式是以交叉堆疊方式打包(如下圖所示)

image

from 3d-bin-packing.

Related Issues (19)

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.