UttaranB127 / STEP

Spatial Temporal Graph Convolutional Networks for Emotion Perception from Gaits
https://gamma.umd.edu/step
MIT License
69 stars 12 forks source link

Neighbor link in graph.py #9

Closed AndreyGalitsin closed 3 years ago

AndreyGalitsin commented 3 years ago

Dear Uttaran, I want to understand, how have you created a neighbor_link (in graph.py sctript) for you dataset. Can you explain me your idea on openpose example please?

num_node = 18
self_link = [(i, i) for i in range(self.num_node)]
neighbor_link = [(4, 3), (3, 2), (7, 6), (6, 5), (13, 12), (12, 11),
                 (10, 9), (9, 8), (11, 5), (8, 2), (5, 1), (2, 1),
                 (0, 1), (15, 0), (14, 0), (17, 15), (16, 14)]
edge = self_link + neighbor_link
center = 1

openpose

UttaranB127 commented 3 years ago

Could you please point to the file that has these lines? It seems to me that (11, 5) and (8, 2) are incorrect links based on the diagram you shared, they should be (11, 1) and (8, 1) respectively. The other links are similarly the endpoints of the other lines in the figure.

AndreyGalitsin commented 3 years ago

I have seen it there: https://github.com/yysijie/st-gcn/blob/master/net/utils/graph.py#L42

Yes I have confused about (11, 5) and (8, 2). Strange that this code works!

UttaranB127 commented 3 years ago

Hmm I can't comment on their code, but it could be possible they were using a different openpose representation at the time (can't say what that representation could be, though).

AndreyGalitsin commented 3 years ago

Maybe it was the other representation, yes. So thank you, now I understand the idea how to define the neighbor_link