Replies: 1 comment 1 reply
-
Ok. I have managed to do it. Apparently, the markers work like some kind of influence zone... Prepare the markersnumero = 100
x = np.linspace(-25, -10, num=numero)
y=np.linspace(20, 460, num=numero)
result = []
for a in x:
for b in y:
markers1 = np.array([a,b])
result.append(markers1)
markers = np.array(result)
op.topotools.find_surface_pores(network=pn2, markers=markers, label='surface_left')
fig = op.topotools.plot_connections(network=pn2)
fig = op.topotools.plot_coordinates(network=pn2, pores=pn2.pores('surface_left'), ax=fig, c='r')
x, y = markers.T
plt.scatter(x,y)
plt.show() Anyway, if you can help me with the "snow issue", it is still valid. Cheers |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi,
I am facing some problems while labeling the boundary pores to a network extracted using Porespy, and I would like to request some help.
Firstly I would like to check something regarding Porespy:
I have used the following code to perform the PNM generation:
Step-by-step application of the SNOW algorithm
This one does not give me labeled pores for the boundaries.
I know I could have used snow2, which would make my life easier, but could I change the sigma (or something similar in this code)? Apparently, this code brought some over-segmentation and a lack of connections between the pores.
Automatic Snow algorithm
Second, on the network extracted using the
ps.networks.regions_to_network()
function, I tried to label by using theop.topotools.find_surface_pores
functions. Unfortunately, when trying to extract top, bottom, left, right boundaries, I could not handle them.I have tried using markers in the code above (like in this example https://notebook.community/PMEAL/OpenPNM/examples/topology/Adding%20Boundary%20Pores) and setting the "top" labels afterward using the following command but without success.
pn2.set_label(pores=pn2.pores('surface')[1:30], label='pore.top')
Could you help me with this issue? Is there any detail regarding the markers that I am not taking into consideration?
Thanks in advance!
Fernando
Beta Was this translation helpful? Give feedback.
All reactions