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

couldn't compile MuJoCo.jl #10

Open
ZhaomingXie opened this issue Jan 28, 2020 · 9 comments
Open

couldn't compile MuJoCo.jl #10

ZhaomingXie opened this issue Jan 28, 2020 · 9 comments

Comments

@ZhaomingXie
Copy link

Hi
I encounter this error message while trying "using MuJoCo":

ERROR: LoadError: LoadError: InitError: could not load library "/home/zhaoming/.julia/artifacts/958f14ac09ce5cc2f5f6ec439a48b868513d6c5c/lib/libGL.so"

/home/zhaoming/.julia/artifacts/958f14ac09ce5cc2f5f6ec439a48b868513d6c5c/lib/libGL.so: undefined symbol: _glapi_tls_Current

I try googling it and couldn't find anything related. Any help will be appreciated, Thanks!

@colinxs
Copy link
Contributor

colinxs commented Jan 30, 2020

Hi @ZhaomingXie!

Could you attach the Project.toml, Manifest.toml, and printout of versioninfo() so I can try and figure out what's going on? Here's a code snippet to help:

using Pkg
function getinfo(dstpath::AbstractString)
    mktempdir() do dir
        env = Pkg.Types.Context().env
        Pkg.Types.write_project(env.project, joinpath(dir, "Project.toml"))
        Pkg.Types.write_manifest(env.manifest, joinpath(dir, "Manifest.toml"))
        open(joinpath(dir, "versioninfo.txt"), "w") do io
            versioninfo(io)
        end
        Pkg.PlatformEngines.probe_platform_engines!()
        Pkg.PlatformEngines.package(dir, dstpath)
    end
end

just run getinfo("path/to/info.tar.gz") and attach that tarfile!

Thanks!
Colin

p.s. I see you're working on some Cassie projects. We're working on integrating Cassie into Lyceum, a new robotics framework that we created, and would love feedback from someone familiar with the system.

image

@ZhaomingXie
Copy link
Author

Hi @colinxs
Many thanks for your help! Attached are the requested files.

Re: Cassie. Yes! I am happy to help with Cassie integration.

info.tar.gz

@colinxs
Copy link
Contributor

colinxs commented Jan 30, 2020

@ZhaomingXie

This may be related to a similar issue that I ran into on Mac machines in MuJoCo_jll that was patched. Can you try running Pkg.update() and see if that alleviates the problem? You should see something like:

  [32af7c3b] ↑ MuJoCo_jll v2.0.0+0 ⇒ v2.0.0+1

@ZhaomingXie
Copy link
Author

@colinxs
Thanks for the help!
It seems like the copy of libGL.so in .julia is broken somehow. I link it to my local copy of libGL.so and it works now.

@colinxs
Copy link
Contributor

colinxs commented Jan 30, 2020

Glad to hear you found a workaround! Did the update not work?

We test against linux/macos/windows with that libGL.so (the CI runners don't provide libGL.so themselves), so if you found a bug I'd like to figure out what's unique about your system. If you could tell me a bit more information that'd be helpful!

  1. When you linked the libGL.so, how exactly did you do it?
  2. What linux platform/version are you on?
  3. Do you have a GPU, if so what driver version? For nvidia you can copy-paste the output of nvidia-smi.
  4. Did you specify a LD_LIBRARY_PATH?

Thank you @ZhaomingXie !

@ZhaomingXie
Copy link
Author

Happy to help! The update didn't work and I needed to do something else. Here are the answers to your questions:

  1. I linked it using command: ln -s /usr/lib32/nvidia-418/libOpenGL.so /home/zhaoming/.julia/artifacts/958f14ac09ce5cc2f5f6ec439a48b868513d6c5c/lib/libGL.so. I also needed to do it for libOpenGL.so, libGLESv2.so and libGLESv1_CM.so. They all complain about " undefined symbol: _glapi_tls_Current".

  2. I am working on Ubuntu 16.04.

  3. The output of nvidia-smi is: NVIDIA-SMI 418.87.01 Driver Version: 418.87.01 CUDA Version: 10.1 .

  4. No I didn't specify LD_LIBRARY_PATH.

Hope that helps.

@klowrey
Copy link
Contributor

klowrey commented Jan 31, 2020

@ZhaomingXie What Linux kernel are you on? I'm just curious; you can run uname -a to find out.

@colinxs
Copy link
Contributor

colinxs commented Jan 31, 2020

Thanks for sending that to me. I can't be sure without inspecting your system, but judging by /usr/lib32/nvidia-418/ it looks like you're using 32-bit nvidia drivers on a 64-bit machine? If you purged your system of nvidia drivers and reinstalled the 64-bit versions then MuJoCo should work out of the box.

Also, keep in mind that that symlink may throw an error during a Pkg update or if you re-install the same version of MuJoCo_jll (installed automatically by MuJoCo).

@ZhaomingXie
Copy link
Author

@klowrey
The output of unmae -a is: 4.15.0-74-generic #83~16.04.1-Ubuntu SMP Wed Dec 18 04:56:23 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux.

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

3 participants