jerhoud / zernike3d

Programs and library for the computation of 3D Zernike moments (point clouds or triangular meshes).
GNU General Public License v3.0
4 stars 4 forks source link

Rotational invariants from Zernike 3D moments #1

Open eloyvallinaes opened 1 year ago

eloyvallinaes commented 1 year ago

Hi!

I've been looking for a piece of software like yours for a while and I am simply delighted I came across your repo. I am trying to obtain rotational invariants for protein surfaces. I have successfully installed and ran your package but I have a few practical questions:

  1. Is there a way to calculate the invariants directly, like the README seems to imply? If so, I can't for my life find it.
  2. In the output of Shape2Zernike, the value of the moment can be real or complex, the latter being written in the form a+bi?
  3. Is there away to run this calculation on a point cloud? Again the README seems to indicate that but I can't figure out how to do it. I tried setting the number of faces to 0 in the OFF file and removing the lines describing the faces, but then 0 steps are performed.

Many thanks!

GeraldR101 commented 1 month ago

Hi,

I also need software that calculates 3D Zernike descriptors. This code has a lot of potential. Starting with Eloy's questions:

  1. I need this too. Can it be calculated from the output? I get the first two indices as l and m. What is the third?
  2. I think it is a+bi. There seems to be code to give REAL results too which is controlled by a hidden parameter -r.
  3. From my weak knowledge of the algorithm this uses, it needs the faces of the object.

Thank you

GeraldR101 commented 1 month ago

Hi,

I added this code to Shape2Zernike.cpp just before it generates the output of of the Zernike moments:

  rotational_invariants zd;
  zd = rotational_invariants(N);
  zd.eval_ri(zm);
  out << zd;
  signature_invariants zsd;
  zsd = signature_invariants(N);
  zsd.eval_si(zm);
  out << zsd;

The output of the rotationally invariant moments has indices similar to the moments output. Based on my understanding there are too many of them. The signature output has only one index. The number of values is the same as the order N. According to my understanding there should have been more of them.