openxrlab / xrfeitoria

OpenXRLab Synthetic Data Rendering Toolbox
https://xrfeitoria.readthedocs.io
Apache License 2.0
238 stars 17 forks source link

A bug in blender amass #19

Closed ChenyangWang95 closed 1 month ago

ChenyangWang95 commented 9 months ago

hi, when I apply the 07_amass.py, error occurs.

type object 'XRFeitoriaBlenderFactory' has no attribute 'apply_motion_data_to_actor'  
File "E:\Project\xrfeitoria\xrfeitoria\utils\functions\blender_functions.py", line 69
HaiyiMei commented 9 months ago

Sorry, for that. Please try to use dev_plugins first:

git clone https://github.com/openxrlab/xrfeitoria.git
cd xrfeitoria
pip install .
python -c "import xrfeitoria as xf; xf.init_blender(replace_plugin=True, dev_plugin=True)"

This would be a formal feature when a new version is released.

Time-Lord12th commented 9 months ago

Sorry, for that. Please try to use dev_plugins first:

git clone https://github.com/openxrlab/xrfeitoria.git
cd xrfeitoria
pip install .
python -c "import xrfeitoria as xf; xf.init_blender(replace_plugin=True, dev_plugin=True)"

This would be a formal feature when a new version is released.

Sorry to interrupt, I run your command and add replace_plugin=True, dev_plugin=True to blender.07_amass.py. But there's a new error ImportError: cannot import name 'Dict' from 'xrfeitoria.utils.functions.blender_functions'. Could you tell me how to solve it? Thanks! image

HaiyiMei commented 9 months ago

Sorry, for that. Please try to use dev_plugins first:

git clone https://github.com/openxrlab/xrfeitoria.git
cd xrfeitoria
pip install .
python -c "import xrfeitoria as xf; xf.init_blender(replace_plugin=True, dev_plugin=True)"

This would be a formal feature when a new version is released.

Sorry to interrupt, I run your command and add replace_plugin=True, dev_plugin=True to blender.07_amass.py. But there's a new error ImportError: cannot import name 'Dict' from 'xrfeitoria.utils.functions.blender_functions'. Could you tell me how to solve it? Thanks! image

I don't know the exact reason why this happened. But I noticed in the second line, the log says Reuse existing engine process. This message suggests that an instance of Blender is already running. To address this, you can try terminating the existing Blender process and then try to run the code again. This may resolve the issue.

XRFeitoria would first search for an existing engine process for efficiency. Once found, it would reuse the engine, and execute the following codes on this existing engine. Normally, this would be fine, but when using the existing engine, the dev_plugin and replace_plugin are ignored actually, which would cause failure in replace_plugin.

Time-Lord12th commented 9 months ago

@HaiyiMei You're right. Problem solved, thanks!

HaiyiMei commented 8 months ago

Hi @Time-Lord12th @ChenyangWang95, we released v0.6.0 of XRFeitoria.

Please update using:

pip install xrfeitoria -U

And you may need to use xf.init_blender(..., replace_plugin=True)