[BUG]: 3D front check folders but not name of pictures-normals
Describe the bug When loading a normal texture of an already loaded texture (image) that exists, program crashes because the path is there. Specufucakktm we go to _load_and_create which returns the warning, but then _get_used_image does not have the information bc we move from the texture to the normaltexture spaces.
General Information
-
Which BlenderProc version are you using? Latest
-
On which operating system are you? Ubuntu/Windows
-
Have you checked the issue tracker to see if a similar issue has been opened? Yep
-
Have you changed BlenderProc in any way besides the config file? If yes, are you sure that this change does not affect the problem you are having? No, Yep
To Reproduce Steps to reproduce the behavior:
- Provide the full command you used to run BlenderProc:
blenderproc run examples/front_3d/main.py b61bb1d3-460f-4c19-9ac0-d8bf6512825b ...
Additional context
D:\BlenderProc\blenderproc\python\loader\TextureLoader.py:75: UserWarning: Image P:\irotate\3DFRONT\3D-FRONT-texture\437a05ce-bac8-4855-b7e4-b09c7a154722\texture.png has been already loaded and a corresponding texture was created. Following the save behaviour of reducing the overhead, it is skipped. So, if you really need to load the same image again (for example, in a different or in the same colorspace), use the copy of the file.
File "C:\Users\ebonetto\Desktop\untitled.blend\main.py", line 39, in <module>
File "D:\BlenderProc\blenderproc\python\loader\Front3DLoader.py", line 68, in load_front3d
created_objects = Front3DLoader._create_mesh_objects_from_file(data, front_3D_texture_path,
File "D:\BlenderProc\blenderproc\python\loader\Front3DLoader.py", line 236, in _create_mesh_objects_from_file
normal_map = mat.nodes.new("ShaderNodeNormalMap")
File "D:\BlenderProc\blenderproc\python\loader\Front3DLoader.py", line 139, in _get_used_image
raise Exception(f"There is not just one texture: {len(textures)}")
Exception: There is not just one texture: 0
Error: Python script failed, check the message in the system console
The problem seems twofold. On one hand the folder 437... has the texture.png which is correctly loaded. Then, when checking for the normal texture, the code recognize such folder in bpy.data.images and return "yep I have it" however it's missing the file. Might be worth it to try to isolate such checks. O couldn't explore more this evening. I'll probably have time tomorrow to give a better look.
Also, in _load_and_create no texture is returned if the warning is triggered, which does not seem right at a first glance.
Hey @themasterlink did you had the chance to try this out? After exploring a bit the code, there seems to be no easy solution as even if we maintain two separate lists we would end up loading the texture,png instead of the normal one.
Hey,
sorry not yet. I will try to have a look at it in the upcoming days.
Best, Max
Hi guys, is this solved? I'm having the same issue :(
nope, I've tried a couple of things but I ended up disabling it.
@themasterlink few lines afterwards, in the else, the obj.name should be probably changed to used_obj_name.
Hey,
sorry for the delay, but right now is conference deadline marathon.
I will get to this afterwards.
Best, Max
Noprob, I'm kinda in that too ;) this just crashed there yesterday was just signaling avoiding an issue for a one-liner
On Thu, 24 Feb 2022, 16:40 Maximilian Denninger, @.***> wrote:
Hey,
sorry for the delay, but right now is conference deadline marathon.
I will get to this afterwards.
Best, Max
— Reply to this email directly, view it on GitHub https://github.com/DLR-RM/BlenderProc/issues/449#issuecomment-1049987371, or unsubscribe https://github.com/notifications/unsubscribe-auth/AEXDUJTPJ3HUBPY4UIKDO73U4ZGQNANCNFSM5NGRNHVA . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.
You are receiving this because you authored the thread.Message ID: @.***>
Sorry for the immense delay. Is this still an issue?
I've not checked anymore. I went around this and skipped it. Sorry.
On Thu, Aug 25, 2022 at 12:06 AM Maximilian Denninger < @.***> wrote:
Sorry for the immense delay. Is this still an issue?
— Reply to this email directly, view it on GitHub https://github.com/DLR-RM/BlenderProc/issues/449#issuecomment-1226861171, or unsubscribe https://github.com/notifications/unsubscribe-auth/AEXDUJRBRO3QMZ6L2PNBBWDV24LO5ANCNFSM5NGRNHVA . You are receiving this because you authored the thread.Message ID: @.***>