<div dir="ltr">Hi,<div><br></div><div>I am trying to use graph.MCP_Geometric(costs) on a cluster. The script and methods I use work on my personal computer which has 64GB memory. I am now trying to implement the same code on a cluster using IPython parallel. Here's the problem, each node/task only has about 20GB memory so they cannot even complete the </div><div><br></div><div>mcp=graph.MCP_Geometric(costs)<br></div><div><br></div><div>command. My cost data has shape (12837, 43345). </div><div><br></div><div>I am trying IPython parallel since I think it should allow me to overcome the lack of memory in each node. E.g. If I define a parallel function like</div><div><br></div><div><div>@dview.parallel(block=True)</div><div>def costsnx(costs):</div><div>    mcp=graph.MCP_Geometric(costs)</div><div>    return mcp</div></div><div><br></div><div>and run it</div><div><br></div><div>mcpp=costsnx(costs)</div><div><br></div><div>I get a list with mcp objects like <skimage.graph._mcp.MCP_Geometric at 0x2d6fdd0>, one for each process I created. So in principle this would solve the memory problem, but the individual mcp objects do not seem to work e.g. executing </div><div><br></div><div>mcpp[30].find_costs([[0,0]])</div><div><br></div><div>generates</div><div><br></div><div><div>TypeError: object of type 'NoneType' has no len()</div></div><div><br></div><div>Also, there is no way to join them to recreate the real graph. I tried also including the </div><div><br></div><div>mcp.find_costs(location)<br></div><div><br></div><div>command in the parallel function, but it cannot find the location. I was thinking that perhaps there would be a way to use the intermediate steps of the graph.MCP_Geometric function to get the indices or something that could be constructed in parallel and then joined back into a unique element to compute minimum_costs.</div><div><br></div><div>Any ideas on how this could be implemented? Or any idea on how to tackle the problem at all?</div><div><br></div><div>I appreciate any help or pointers.</div><div><br></div><div>Thanks</div><div><br></div><div>OOM</div><div><br></div></div>