DLR-RM / BlenderProc

A procedural Blender pipeline for photorealistic training image generation
GNU General Public License v3.0
2.74k stars 443 forks source link

Show warning on mac when custom pip package path is not writable #768

Open cornerfarmer opened 1 year ago

cornerfarmer commented 1 year ago

See https://github.com/DLR-RM/BlenderProc/pull/767#issuecomment-1332331345

On Mac OS, you have to add in the general settings that your terminal is allowed to perform updates. Else it can not execute the pip installs. That is interesting.

Maybe we should add a warning if:

PermissionError: [Errno 1] Operation not permitted: '/Users/max/blender/blender-3.3.0-macos-x64/Blender.app/Contents/Resources/custom-python-packages'

ShreyaKapoor18 commented 1 year ago

I am getting the same error, has someone found a solution to this?

cornerfarmer commented 1 year ago

Did you try to add in the general settings that your terminal is allowed to perform updates.?

ShreyaKapoor18 commented 1 year ago

@cornerfarmer I did add this, and was able to install.

I made a virtualenv and install h5py with brew but now when I do blenderproc quickstart

I get an error 'no module named h5py'

cornerfarmer commented 1 year ago

Probably h5py is not found inside blenders python environment. Usually this should be installed automatically on the first run, but could you try installing it manually via:

blenderproc pip install h5py
ShreyaKapoor18 commented 1 year ago

@cornerfarmer Hi and thank you for your reply. I ran this command, it did install h5py After this I ran blenderproc quickstart

but this resulted in the same error h5py not found

shockjiang commented 10 months ago

Did you try to add in the general settings that your terminal is allowed to perform updates.?

@cornerfarmer I met the same error and I think I know what you mean. But how to "add in the general settings that your terminal is allowed to perform updates"? could you give a short description? I am a fresh of blender/blenderproc.

cornerfarmer commented 10 months ago

I dont have a mac to test it, but it should be doable as described here: https://stackoverflow.com/a/59250494

shockjiang commented 10 months ago

@cornerfarmer works for me! thank you!

alvaro-budria commented 3 months ago

@cornerfarmer Hi and thank you for your reply. I ran this command, it did install h5py After this I ran blenderproc quickstart

but this resulted in the same error h5py not found

Hi, I am facing the same situation. Even after allowing updates from my terminal as @cornerfarmer, I am getting ModuleNotFoundError: No module named 'h5py' error.

Did you find a solution?

cornerfarmer commented 2 months ago

Hey @alvaro-budria,

just running blenderproc pip install h5py should fix that. Alternatively you can also switch to the main github branch version. There this error should not occur anymore.

ivanpuhachov commented 6 days ago

Just installed blenderproc on m1 mac, blenderproc quickstart worked with no errors. As mentioned by first comment

See https://github.com/DLR-RM/BlenderProc/pull/767#issuecomment-1332331345

On Mac OS, you have to add in the general settings that your terminal is allowed to perform updates. Else it can not execute the pip installs. That is interesting.

Otherwise I had error like ERROR: Could not install packages due to an OSError: [Errno 1] Operation not permitted: '/Users/ivan/blender/blender-3.5.1-macos-x64/Blender.app/Contents/Resources/3.5/python/lib/python3.10/site-packages/pip/__init__.py'

image

I think this issue can be closed.