deepdrive-sim icon indicating copy to clipboard operation
deepdrive-sim copied to clipboard

Editor crash on opening project.

Open shantanusingh16 opened this issue 5 years ago • 13 comments

Hi, I've tried compiling the v3 and v3_stable branch of this repo, but everytime it crashes the editor during launch at around 71% with 'Segmentation fault: illegal memory reference (signall 11) just after launching the python vm. I've downloaded the UnrealEnginePython fork from deepdrive repositories as well as the original one from the 20tab, but get the same issue.

Can anyone please help me out here? I've been stuck with this for about a week now. Can anyone list the steps to get the simulator open and running in the editor, please?

Thanks, Shantanu

shantanusingh16 avatar Sep 17 '19 20:09 shantanusingh16

Hi @shantanusingh16 - sorry! - looking into it!

crizCraig avatar Sep 17 '19 20:09 crizCraig

So there was a segfault I just fixed due to a version mismatch between our Python bindings and the sim. This should be fixed if you pull latest from branch v3. Also, make sure you run ./clean_all.sh to clean old binaries after pulling. Then run

pip uninstall deepdrive
pip install deepdrive==3.0.20190917221041.dev0

to get the latest pre-built bindings from the same v3 branch. I suggest the uninstall in case you built the bindings locally in which case things like --upgrade and forcing reinstall don't work.

Then run via these instructions

crizCraig avatar Sep 17 '19 23:09 crizCraig

So that fixes the packaged version, but perhaps not the editor. Hold tight.

crizCraig avatar Sep 17 '19 23:09 crizCraig

Okay, I've reproduced the issue, but can't seem to find the problem. @dnsmernst and I may need to discuss.

crizCraig avatar Sep 18 '19 01:09 crizCraig

@crizCraig Thanks for the quick reply. I've been debugging this and it seems to be a problem of the UnrealEnginePython plugin and not this repository. I was able to reproduce the same bug in a new C++ project created using Unreal Editor. I've created an issue on that repo. Will update here once I get a response from there.

shantanusingh16 avatar Sep 18 '19 13:09 shantanusingh16

@shantanusingh16 - I'm not sure if the numpy issue you posted is related, but I have found a fix for the problem I reproduced. Can you please try

cd ~/UnrealInstalled/Engine/Plugins/UnrealEnginePython/EmbeddedPython/Linux/bin
./python3 -m pip install pyarrow==0.12.1

crizCraig avatar Sep 18 '19 18:09 crizCraig

@crizCraig For me the EmbeddedPython directory is empty, even after compiling the project using the editor. But I have followed the traditional setup instructions and not the docker ones as I'm short of disk space. I

shantanusingh16 avatar Sep 18 '19 18:09 shantanusingh16

Ah, so UnrealEnginePython must be in your deepdrive-sim directory then. Same command should work there!

crizCraig avatar Sep 18 '19 18:09 crizCraig

It's there in the Plugins directory. But there are no sub-directories 'Linux/bin' within the EmbeddedPython directory. Also pip list shows that I already have pyarrow, pyzmq and requests (the dependencies that you check in ue_site.py) already installed for my python installation.

shantanusingh16 avatar Sep 18 '19 18:09 shantanusingh16

Hmm, can you please send a gist with the complete output of your build?

crizCraig avatar Sep 18 '19 18:09 crizCraig

I can do it after a few hours as its on my work pc and I'm already came back for the day.

shantanusingh16 avatar Sep 18 '19 18:09 shantanusingh16

@crizCraig Here you go. Gist

Let me know if anything else is needed.

shantanusingh16 avatar Sep 21 '19 16:09 shantanusingh16

Looks like a relatively low-level error

Signal 6 caught.

Can you ensure you're using our fork of UEPy? Also, it looks like your compiler is reporting as

[GCC 8.3.0]

Which is quite different from what I typically see

2019-09-20T22:41:29.015624576Z [GCC 4.2.1 Compatible Clang 6.0.1 (tags/RELEASE_601/final)]

Unreal downloads a compiler toolchain during Setup.sh in a local setup, but I'm not sure you have that correctly configured.

First though, I would try using our prebuilt UEPy in the deepdrive-sim project's Plugins folder. This comes with an embedded python in which we install some requirements to in ensure_requirements which seems to be what is triggering the malloc error. Otherwise a local python is used, which seems to be the right version (3.6.8), but may not allow those requirements to be installed. Also, even though the above plugin is pre-built, I've found that UEPy must be rebuilt inside the project with the traditional install whereas it doesn't with the export install. After the plugin is built inside the project, you can move it to the engine plugins folder to avoid rebuilding again.

@adamrehn or @dnsmernst - do you have any insights here?

You may want to try the export setup as much easier option if you can get some disk space.

crizCraig avatar Sep 23 '19 19:09 crizCraig