You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Several months ago I implemented a greedy edge-coloring algorithm to identify batches of pipes that can run in parallel. Basically, all the pipes are edges between slot group nodes, and each color represents pipes that will be run in parallel. Then each color gets run sequentially.
It's very fast in runtime, but since the coloring can be far from optimal, and each color takes at least 20ms to run because of how Minecraft works, it's probably worth it to use a slower runtime but more optimal coloring algorithm.
DSatur looks like a good bet; the runtime doesn't take a super massive hit O((n+m)logn) if you use a binary heap versus the existing O(n+m), or better with a fibonacci heap. I have a lua binary heap implementation left over from when I made JackJack, so we can use that.
RLF is even slower runtime but better coloring, but maybe if we cache the graph coloring between runs it won't be so bad. We need a way to store a "factory version" every time the factory gets edited, which might be a little involved.
I stopped playing my modded Minecraft playthrough a while ago, so I haven't been motivated to implement this stuff. But if I play more modded again, I might try implementing this.
The text was updated successfully, but these errors were encountered:
Several months ago I implemented a greedy edge-coloring algorithm to identify batches of pipes that can run in parallel. Basically, all the pipes are edges between slot group nodes, and each color represents pipes that will be run in parallel. Then each color gets run sequentially.
It's very fast in runtime, but since the coloring can be far from optimal, and each color takes at least 20ms to run because of how Minecraft works, it's probably worth it to use a slower runtime but more optimal coloring algorithm.
DSatur looks like a good bet; the runtime doesn't take a super massive hit
O((n+m)logn)
if you use a binary heap versus the existing O(n+m), or better with a fibonacci heap. I have a lua binary heap implementation left over from when I made JackJack, so we can use that.RLF is even slower runtime but better coloring, but maybe if we cache the graph coloring between runs it won't be so bad. We need a way to store a "factory version" every time the factory gets edited, which might be a little involved.
I stopped playing my modded Minecraft playthrough a while ago, so I haven't been motivated to implement this stuff. But if I play more modded again, I might try implementing this.
The text was updated successfully, but these errors were encountered: