ZikangZhou / HiVT

[CVPR 2022] HiVT: Hierarchical Vector Transformer for Multi-Agent Motion Prediction
https://openaccess.thecvf.com/content/CVPR2022/papers/Zhou_HiVT_Hierarchical_Vector_Transformer_for_Multi-Agent_Motion_Prediction_CVPR_2022_paper.pdf
Apache License 2.0
577 stars 115 forks source link

how can i use only one subgraph? #26

Closed zsgj-Xxx closed 1 year ago

zsgj-Xxx commented 1 year ago

I masked other vehicles, made sure only one moving vehicle was left in each scene, and tried to predict the track, which resulted in my edge_ Index is an empty list and cannot continue. What is a good solution?

ZikangZhou commented 1 year ago

Hi,

Thanks for your interest. You can write something like this:

edge_index = torch.tensor([[], []], dtype=torch.long)

This will create an edge index tensor with the shape of [2, 0], and then you can pass this tensor to the model in the forward pass.

zsgj-Xxx commented 1 year ago

Thank you for your quick response!

You're right, I've got the results.