Click here to Skip to main content
15,848,264 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
I have two files with nrrd extension. I am reading them by using nrrd module and saving to 3D array. Now I have two 3D arrays and I want to calculate fastly hausdorff distance between them in pixel. And I have to use python.

Here is the small part of my 3D array. They both have the same dimensions.

Shape: (512, 512, 109)

[[[0 0 0 ... 0 0 0]
[0 0 0 ... 0 0 0]
[0 0 0 ... 0 0 0]
...
[0 0 0 ... 0 0 0]
[0 0 0 ... 0 0 0]
[0 0 0 ... 0 0 0]]

[[0 0 0 ... 0 0 0]
[0 0 0 ... 0 0 0]
[0 0 0 ... 0 0 0]
...
[0 0 0 ... 0 0 0]
[0 0 0 ... 0 0 0]
[0 0 0 ... 0 0 0]]

What I have tried:

I researched many algorithm in the google but most of them about 2D arrays. Please help me.
Posted
Updated 15-Dec-21 23:13pm
Comments
Richard MacCutchan 16-Dec-21 4:11am    
Since all the elements of the arrays appear to be zero, then any difference is likely to be the same.
Enes Şahin 2021 16-Dec-21 16:18pm    
NOT ALL ELEMENTS OF THE ARRAY 0

1 solution

 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900