create vector shape from molecule [closed]

asked 2017-06-03 15:05:40 -0600

tevang2 gravatar image

updated 2017-06-04 17:29:26 -0600

Greetings everyone,

I would like to calculate the Hu moments of some molecules (collection of atoms with known coordinates and radii). In the documentation says that the function accepts vector shapes or rasterized shapes. Could someone please point out how can I create a vector shape for each of my molecules ( I have no images of them, only 3D coordinates of atoms and radii)?

edit retag flag offensive reopen merge delete

Closed for the following reason question is not relevant or outdated by sturkmen
close date 2020-09-26 16:56:17.224453

Comments

yes, you can pass a vector of 2d points, an outline. but (sparse) 3d centers ? not really.

berak gravatar imageberak ( 2017-06-03 19:40:10 -0600 )edit

Do you think it is a good idea to project the 3D coordinates of the centers to 2D using a dimensionality technique like Isomap http://scikit-learn.org/stable/module... ?

tevang2 gravatar imagetevang2 ( 2017-06-04 07:27:48 -0600 )edit

"I would like to calculate the Hu moments some molecules" -- so, what kind of answer do you expect from that ?

berak gravatar imageberak ( 2017-06-04 07:32:23 -0600 )edit
1

My dataset consists of small organic molecules with pharmaceutical interest. For each of them I know the 3D coordinates of their atoms, the bonds that connect them and their atomic radii. From these properties I would like to calculate feature vectors describing the molecular shape in order to be used for the training of a Neural Network. I work with specific molecular visualization software, which read in specific file formats that contain these properties (.mol2, .sdf). Thereby I am not familiar with the file formats you people work with OpenCV and I would like to understand if I can generate that format from my data. The OpenCV documentation states a vague term "vector shape" which I cannot comprehend. Is everything more clear now? Obviously I am new to OpenCV.

tevang2 gravatar imagetevang2 ( 2017-06-04 13:42:17 -0600 )edit

ah, thanks for the helpful explanation.

unfortunately, opencv expects you to have either a b/w image or a vector<Point> with the outline of your shape(here is one), so i do not think, that any "2d embedding" of your dataset will result in something meaningful.

berak gravatar imageberak ( 2017-06-05 01:07:16 -0600 )edit

Do you believe that reducing the 3 dimensions to 2 using a technique like Isomap won't result to something meaningful for Hu moments calculation?

tevang2 gravatar imagetevang2 ( 2017-06-05 07:19:07 -0600 )edit