Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can not generate trajectories #3

Open
MzXuan opened this issue Nov 22, 2018 · 10 comments
Open

Can not generate trajectories #3

MzXuan opened this issue Nov 22, 2018 · 10 comments

Comments

@MzXuan
Copy link

MzXuan commented Nov 22, 2018

Hi, Thanks for your code.

However, our trajectory generation seems does not work well. We can not see a complete trajectory from the viewer.
The viewer shows trajectory generation procedure as follows,
1111
And the recorded result in the file below.
2018-11-22-viewer.03.ppms.gz

Here is our code to generate trajectories.

Thanks for your help.

@ahq1993
Copy link
Owner

ahq1993 commented Nov 22, 2018

Hi,
Try setting up following
-->graph_renderer.cpp
i=0 // line 192
-->rrts_main.cpp
(i=0;i<1;i++) //line96
int t=0;t<100;t++ //line111

Thanks for pointing it out. I noticed the code is looping over environments rather than random start and goal. I have updated the code either use revised repo or modify the above line in your code and see if it works.

@MzXuan
Copy link
Author

MzXuan commented Nov 23, 2018

Hi,
Thanks for your reply.

I still have some problems on generating trajectories. In rrt_main.cpp line 107,

path="graph/graph"+env_no+".dat";

Seems you read a graph_envno.data which contains the start and goal point. However, I can not find where to generate this graph file.
Can you help me to fix it?

Thank you very much.

@doctorsrn
Copy link

doctorsrn commented Nov 27, 2018

@MzXuan
Hi,
I meet the same problem that can not see a trajectory from the viewer, even though I have updated the code and modify some lines. Do you fix it?

Thank you very much.

@MzXuan
Copy link
Author

MzXuan commented Dec 3, 2018

@doctorsrn
No, I haven't..

@ahq1993
Copy link
Owner

ahq1993 commented Dec 3, 2018

Hi,
Sorry for the late response. I have tested the code, and it is working perfectly fine. If you see line 111 in rrts_main.cpp, the algorithms loads graph files from the graph folder which I think aren't linked in your code. Here are the quick steps to make it work:
1- Download graph.zip and place the unzipped graph folder in the data_generation.
2- I also included the following lines (line 55-56) in the rrts_main.cpp
string env_path="env";
mkdir(env_path.c_str(),ACCESSPERMS);
The above lines will automatically create an "env" folder where the data_generation code will save the generated paths.

@bbrito
Copy link

bbrito commented Dec 7, 2018

I tried your solution and it creates the following error:

error: expected constructor, destructor, or type conversion before ‘(’ token
mkdir(env_path.c_str(),ACCESSPERMS); // create folder with env label to store generated trajectories

Do you know how to fix it? Or am I doing something wrong?

@bbrito
Copy link

bbrito commented Dec 7, 2018

I moved line 56 to line 63 and then it compiles fine. I don't know if this is a proper fix.

@doctorsrn
Copy link

@ahq1993
Hi,
Thanks for your reply. I follow your steps and meet the same error as @bbrito . After I move the line56 mkdir(env_path.c_str(),ACCESSPERMS); to the main function, it compiles with no error. And now the viewer and rrtstar works normally.

@ZQ32
Copy link

ZQ32 commented Dec 4, 2019

@ ahq1993
嗨,
谢谢您的答复。我按照您的步骤操作,遇到了与@bbrito相同的错误。将line56 mkdir(env_path.c_str(),ACCESSPERMS); 移至main函数后,它编译无误。现在viewerrrtstar可以正常使用。

I performed your operation, and there was no problem in compiling, but running the rrtstare and viewer executable files, the following situations occurred, can you help solve it?
Screenshot from 2019-12-04 09-10-47
Screenshot from 2019-12-04 09-10-27

@yaozhixin3190
Copy link

@ ahq1993
嗨,
谢谢您的答复。我按照您的步骤操作,遇到了与@bbrito相同的错误。将line56 mkdir(env_path.c_str(),ACCESSPERMS); 移至main函数后,它编译无误。现在viewerrrtstar可以正常使用。

I performed your operation, and there was no problem in compiling, but running the rrtstare and viewer executable files, the following situations occurred, can you help solve it?
Screenshot from 2019-12-04 09-10-47
Screenshot from 2019-12-04 09-10-27

I have met the same bug, did you solve it?

scchow added a commit to scchow/MPNet that referenced this issue Jun 13, 2023
- This commit fixes issues ahq1993#3 ahq1993#4 from the original MPNet repository
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants