Description
Following the Quickstart tutorial, I was unable to get f.connect() to generate any connections.
The pipeline runs without crashing, but the connection step fails to produce results. The output is:
C:\Users...\svv\tree\branch\bifurcation.py:222: RuntimeWarning: Method L-BFGS-B cannot handle constraints.
result = minimize(cost, x0, bounds=[(0.05, 0.95), (0.05, 0.95)], callback=callback,
Collision detected 0-1.
Collision detected 0-0.
Function data shape: 1540
Calculating optimal assignment...
ERROR: Could not find optimal assignment. Try increasing the number of neighbors allowed in search.
After this, no connections are created:
tc = f.connections.tree_connections[0]
print(tc.assignments) # []
print(tc.connections) # 0
Both outputs are empty. Is this behavior expected under certain geometry/tree configurations, or does it indicate a potential issue in the connection/assignment step? If expected, could you clarify what minimum conditions (e.g., tree density, domain scale, or neighbor settings) are required for connect() to generate connections?
Reproduction
Running the code from the quickstart tutorial:
import pyvista as pv
from svv.domain.domain import Domain
from svv.forest.forest import Forest
Creating the Tissue Domain
cube = Domain(pv.Cube())
cube.create()
cube.solve()
cube.build()
Creating the Vascular Forest Object
f = Forest()
f.set_domain(cube)
f.set_roots()
f.add(50)
Form connections
f.connect()
tc = f.connections.tree_connections[0]
print(tc.assignments) # []
print(tc.connections) # 0
Expected behavior
The code is expected to generate multiple vascular trees and then create valid connections between them, resulting in one unified connected network instead of separate trees.
Additional context
No response
Code of Conduct
Description
Following the Quickstart tutorial, I was unable to get f.connect() to generate any connections.
The pipeline runs without crashing, but the connection step fails to produce results. The output is:
C:\Users...\svv\tree\branch\bifurcation.py:222: RuntimeWarning: Method L-BFGS-B cannot handle constraints.
result = minimize(cost, x0, bounds=[(0.05, 0.95), (0.05, 0.95)], callback=callback,
Collision detected 0-1.
Collision detected 0-0.
Function data shape: 1540
Calculating optimal assignment...
ERROR: Could not find optimal assignment. Try increasing the number of neighbors allowed in search.
After this, no connections are created:
tc = f.connections.tree_connections[0]
print(tc.assignments) # []
print(tc.connections) # 0
Both outputs are empty. Is this behavior expected under certain geometry/tree configurations, or does it indicate a potential issue in the connection/assignment step? If expected, could you clarify what minimum conditions (e.g., tree density, domain scale, or neighbor settings) are required for connect() to generate connections?
Reproduction
Running the code from the quickstart tutorial:
import pyvista as pv
from svv.domain.domain import Domain
from svv.forest.forest import Forest
Creating the Tissue Domain
cube = Domain(pv.Cube())
cube.create()
cube.solve()
cube.build()
Creating the Vascular Forest Object
f = Forest()
f.set_domain(cube)
f.set_roots()
f.add(50)
Form connections
f.connect()
tc = f.connections.tree_connections[0]
print(tc.assignments) # []
print(tc.connections) # 0
Expected behavior
The code is expected to generate multiple vascular trees and then create valid connections between them, resulting in one unified connected network instead of separate trees.
Additional context
No response
Code of Conduct