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

feat(light): add utility functions for managing light objects #1173

Merged
merged 2 commits into from
Dec 12, 2024

Conversation

hummat
Copy link
Member

@hummat hummat commented Dec 12, 2024

Similar to the utility functions in MeshObjectUtility this PR does:

  • Introduce get_all_blender_light_objects to retrieve all light objects in the scene
  • Add convert_to_lights to convert Blender light objects to BlenderProc light objects
  • Creates get_all_light_objects to combine the above functionalities for easier access to light objects

- Introduced `get_all_blender_light_objects` to retrieve all light
  objects in the scene.
- Added `convert_to_lights` to convert Blender light objects to
  BlenderProc light objects.
- Created `get_all_light_objects` to combine the above functionalities
  for easier access to light objects.
@cla-bot cla-bot bot added the cla-signed label Dec 12, 2024
@cornerfarmer
Copy link
Member

cornerfarmer commented Dec 12, 2024

BlenderProcHelper result for run 634:

Done with: [amass_human_poses_python 25s, auto_shading_python 9s, basic_python 12s, blenderkit_python 20s, bop_object_on_surface_sampling_python 81s, bop_object_physics_positioning_python 106s, bop_object_pose_sampling_python 37s, bop_scene_replication_python 169s, camera_depth_of_field_python 20s, camera_object_pose_python 10s, camera_random_trajectories_python 60s, camera_sampling_python 20s, coco_annotations_python 14s, diffuse_color_image_python 22s, dust_python 30s, entity_displacement_modifier_python 16s, entity_manipulation_python 10s, front_3d_object_sampling_python 87s, front_3d_python 92s, front_3d_with_improved_mat_python 107s, git_log 1s, haven_python 24s, ikea_python 18s, kinect_azure_noise_python 15s, lens_distortion_python 18s, lens_distortion_python 12s, light_sampling_python 13s, material_manipulation_python 10s, material_randomizer_python 10s, matterport3d_python 65s, motion_blur_rolling_shutter_python 29s, motion_blur_rolling_shutter_python 28s, multi_render_python 288s, nocs_python 19s, object_pose_sampling_python 10s, on_surface_object_sampling_python 10s, optical_flow_python 27s, physics_convex_decomposition_python 126s, physics_positioning_python 23s, pix3d_python 17s, point_clouds_python 16s, random_backgrounds_python 19s, random_room_constructor_python 78s, replica_python 245s, scenenet_python 49s, scenenet_with_cctextures_python 63s, semantic_segmentation_python 13s, shapenet_python 18s, shapenet_with_scenenet_python 56s, shapenet_with_suncg_python 55s, spotlight_python 20s, stereo_matching_python 48s, stereo_matching_with_projector_python 145s, suncg_basic_python 32s, suncg_with_cam_sampling_python 57s, suncg_with_improved_mat_python 66s, suncg_with_object_replacer_python 58s, tests_python 25s, urdf_loading_and_manipulation_python 49s]
Done with 59 of 59 tests.
There were errors:
Unit tests output:

................
----------------------------------------------------------------------
Ran 16 tests in 21.028s

OK

urdf_loading_and_manipulation (main_python)

The output of urdf_loading_and_manipulation:main_python:000000_scene_gt_info_json has changed:

Expand
+ root['0'][2]['bbox_visib'][3]: 22
- root['0'][2]['bbox_visib'][3]: 23
+ root['9'][2]['bbox_visib'][3]: 14
- root['9'][2]['bbox_visib'][3]: 13

stereo_matching (main_python)

The output of stereo_matching:main_python:disparity has changed: Diff: 0.0345, Pixel diff: 0.0033



Compare image Newly generated image

stereo_matching_with_projector (main_python)

The output of stereo_matching_with_projector:main_python:disparity has changed: Diff: 0.0101, Pixel diff: 0.0037



Compare image Newly generated image

Pylint output

Expand

Messages

Module blenderproc (blenderproc/__init__.py)

Line Col. Type Symbol ID Obj Message
12 44 convention trailing-whitespace C0303
Trailing whitespace

Module blenderproc.python.camera.CameraProjection (blenderproc/python/camera/CameraProjection.py)

Line Col. Type Symbol ID Obj Message
4 0 warning unused-import W0611
Unused create_primitive imported from blenderproc.python.types.MeshObjectUtility
10 0 convention ungrouped-imports C0412
Imports from package blenderproc are not grouped
29 31 convention trailing-whitespace C0303
Trailing whitespace
35 0 convention trailing-whitespace C0303
Trailing whitespace
41 0 convention line-too-long C0301
Line too long (147/120)
85 8 refactor no-else-return R1705 depth_at_points_via_raytracing
Unnecessary "else" after "return", remove the "else" and de-indent the code inside it
89 0 convention trailing-whitespace C0303
Trailing whitespace
90 0 convention line-too-long C0301
Line too long (134/120)
141 0 convention trailing-whitespace C0303
Trailing whitespace
159 7 convention trailing-whitespace C0303
Trailing whitespace
161 33 convention trailing-whitespace C0303
Trailing whitespace
165 0 convention line-too-long C0301
Line too long (132/120)
167 0 convention trailing-newlines C0305
Trailing newlines

Module blenderproc.python.loader.BlendLoader (blenderproc/python/loader/BlendLoader.py)

Line Col. Type Symbol ID Obj Message
27 0 convention line-too-long C0301
Line too long (130/120)
100 0 convention trailing-whitespace C0303
Trailing whitespace

Module blenderproc.python.loader.BopLoader (blenderproc/python/loader/BopLoader.py)

Line Col. Type Symbol ID Obj Message
353 0 convention trailing-whitespace C0303
Trailing whitespace

Module blenderproc.python.loader.CCMaterialLoader (blenderproc/python/loader/CCMaterialLoader.py)

Line Col. Type Symbol ID Obj Message
73 0 convention line-too-long C0301
Line too long (152/120)

Module blenderproc.python.postprocessing.PostProcessingUtility (blenderproc/python/postprocessing/PostProcessingUtility.py)

Line Col. Type Symbol ID Obj Message
15 0 convention line-too-long C0301
Line too long (137/120)

Module blenderproc.python.renderer.RendererUtility (blenderproc/python/renderer/RendererUtility.py)

Line Col. Type Symbol ID Obj Message
246 0 convention trailing-whitespace C0303
Trailing whitespace
314 0 convention trailing-whitespace C0303
Trailing whitespace
504 0 convention trailing-whitespace C0303
Trailing whitespace

Module blenderproc.python.types.EntityUtility (blenderproc/python/types/EntityUtility.py)

Line Col. Type Symbol ID Obj Message
170 11 convention unidiomatic-typecheck C0123 Entity.duplicate
Use isinstance() rather than type() for a typecheck.

Module blenderproc.python.types.LightUtility (blenderproc/python/types/LightUtility.py)

Line Col. Type Symbol ID Obj Message
125 12 refactor consider-using-augmented-assign R6104 Light.setup_as_projector
Use '/=' to do an augmented assign directly
216 0 convention trailing-whitespace C0303
Trailing whitespace

Module blenderproc.python.types.MeshObjectUtility (blenderproc/python/types/MeshObjectUtility.py)

Line Col. Type Symbol ID Obj Message
520 87 convention trailing-whitespace C0303
Trailing whitespace
526 0 convention line-too-long C0301
Line too long (122/120)
529 0 convention trailing-whitespace C0303
Trailing whitespace
535 68 warning unused-variable W0612 MeshObject.add_auto_smooth_modifier
Unused variable 'data_from'
543 16 warning self-assigning-variable W0127 MeshObject.add_auto_smooth_modifier
Assigning the same variable 'modifier' to itself
545 0 convention trailing-whitespace C0303
Trailing whitespace
555 0 warning bad-indentation W0311
Bad indentation. Found 9 spaces, expected 8
559 0 convention trailing-whitespace C0303
Trailing whitespace
561 0 warning bad-indentation W0311
Bad indentation. Found 9 spaces, expected 8
562 0 convention trailing-whitespace C0303
Trailing whitespace
564 0 warning bad-indentation W0311
Bad indentation. Found 9 spaces, expected 8
566 0 warning bad-indentation W0311
Bad indentation. Found 13 spaces, expected 12
567 0 warning bad-indentation W0311
Bad indentation. Found 13 spaces, expected 12
568 0 warning bad-indentation W0311
Bad indentation. Found 13 spaces, expected 12
569 90 convention trailing-whitespace C0303
Trailing whitespace
569 0 warning bad-indentation W0311
Bad indentation. Found 13 spaces, expected 12
570 0 warning bad-indentation W0311
Bad indentation. Found 13 spaces, expected 12
571 0 warning bad-indentation W0311
Bad indentation. Found 13 spaces, expected 12
572 0 convention trailing-whitespace C0303
Trailing whitespace
573 23 convention trailing-whitespace C0303
Trailing whitespace
574 0 warning bad-indentation W0311
Bad indentation. Found 9 spaces, expected 8
576 0 warning bad-indentation W0311
Bad indentation. Found 9 spaces, expected 8
577 20 convention trailing-whitespace C0303
Trailing whitespace
578 0 warning bad-indentation W0311
Bad indentation. Found 9 spaces, expected 8
579 0 convention trailing-whitespace C0303
Trailing whitespace
580 0 warning bad-indentation W0311
Bad indentation. Found 9 spaces, expected 8
729 28 convention trailing-whitespace C0303
Trailing whitespace

Module blenderproc.python.utility.Initializer (blenderproc/python/utility/Initializer.py)

Line Col. Type Symbol ID Obj Message
80 0 convention trailing-whitespace C0303
Trailing whitespace

Module blenderproc.python.utility.InstallUtility (blenderproc/python/utility/InstallUtility.py)

Line Col. Type Symbol ID Obj Message
129 0 convention trailing-whitespace C0303
Trailing whitespace

Module blenderproc.python.writer.BopWriterUtility (blenderproc/python/writer/BopWriterUtility.py)

Line Col. Type Symbol ID Obj Message
9 0 convention wrong-import-order C0411
standard import "from typing import List, Optional, Dict, Tuple" should be placed before "import trimesh"
10 0 convention wrong-import-order C0411
standard import "import warnings" should be placed before "import trimesh"
11 0 convention wrong-import-order C0411
standard import "import datetime" should be placed before "import trimesh"
18 0 convention wrong-import-order C0411
standard import "import sys" should be placed before "import trimesh"
62 0 convention line-too-long C0301
Line too long (131/120)
80 8 warning redefined-outer-name W0621 write_bop
Redefining name 'dataset_objects' from outer scope (line 544)
175 12 warning protected-access W0212 write_bop
Access to a protected member _pyrender_init of a client class
177 0 convention line-too-long C0301
Line too long (124/120)
177 48 warning protected-access W0212 write_bop
Access to a protected member _pyrender_init of a client class
177 19 refactor consider-using-with R1732 write_bop
Consider using 'with' for resource-allocating operations
181 0 convention trailing-whitespace C0303
Trailing whitespace
187 0 convention trailing-whitespace C0303
Trailing whitespace
193 12 warning protected-access W0212 write_bop
Access to a protected member _pyrender_cleanup of a client class
313 21 warning redefined-outer-name W0621 _BopWriterUtility.get_frame_gt
Redefining name 'dataset_objects' from outer scope (line 544)
400 38 warning redefined-outer-name W0621 _BopWriterUtility.write_frames
Redefining name 'dataset_objects' from outer scope (line 544)
526 0 convention trailing-whitespace C0303
Trailing whitespace
538 78 convention trailing-whitespace C0303
Trailing whitespace
542 8 warning global-variable-undefined W0601 _BopWriterUtility._pyrender_init
Global variable 'renderer' undefined at the module level
542 8 warning global-variable-undefined W0601 _BopWriterUtility._pyrender_init
Global variable 'renderer_large' undefined at the module level
542 8 warning global-variable-undefined W0601 _BopWriterUtility._pyrender_init
Global variable 'dataset_objects' undefined at the module level
564 8 warning global-variable-undefined W0601 _BopWriterUtility._pyrender_cleanup
Global variable 'renderer' undefined at the module level
564 8 warning global-variable-undefined W0601 _BopWriterUtility._pyrender_cleanup
Global variable 'renderer_large' undefined at the module level
564 8 warning global-variable-undefined W0601 _BopWriterUtility._pyrender_cleanup
Global variable 'dataset_objects' undefined at the module level
570 0 convention line-too-long C0301
Line too long (173/120)
585 78 convention trailing-whitespace C0303
Trailing whitespace
591 8 warning global-variable-not-assigned W0602 _BopWriterUtility._calc_gt_masks_iteration
Using global for 'renderer' but no assignment is done
591 8 warning global-variable-not-assigned W0602 _BopWriterUtility._calc_gt_masks_iteration
Using global for 'dataset_objects' but no assignment is done
598 0 convention trailing-whitespace C0303
Trailing whitespace
689 0 convention line-too-long C0301
Line too long (165/120)
690 0 convention trailing-whitespace C0303
Trailing whitespace
693 0 convention line-too-long C0301
Line too long (196/120)
706 11 convention trailing-whitespace C0303
Trailing whitespace
708 78 convention trailing-whitespace C0303
Trailing whitespace
714 8 warning global-variable-not-assigned W0602 _BopWriterUtility._calc_gt_info_iteration
Using global for 'renderer_large' but no assignment is done
714 8 warning global-variable-not-assigned W0602 _BopWriterUtility._calc_gt_info_iteration
Using global for 'dataset_objects' but no assignment is done
714 8 warning global-variable-not-assigned W0602 _BopWriterUtility._calc_gt_info_iteration
Using global for 'renderer' but no assignment is done
718 11 warning protected-access W0212 _BopWriterUtility._calc_gt_info_iteration
Access to a protected member _renderer of a client class
719 12 warning protected-access W0212 _BopWriterUtility._calc_gt_info_iteration
Access to a protected member _renderer of a client class
720 12 warning protected-access W0212 _BopWriterUtility._calc_gt_info_iteration
Access to a protected member _renderer of a client class
727 0 convention trailing-whitespace C0303
Trailing whitespace
856 0 convention line-too-long C0301
Line too long (207/120)
857 0 convention trailing-whitespace C0303
Trailing whitespace
865 44 warning redefined-outer-name W0621 _BopWriterUtility.calc_gt_coco
Redefining name 'dataset_objects' from outer scope (line 544)

Module blenderproc.python.writer.GifWriterUtility (blenderproc/python/writer/GifWriterUtility.py)

Line Col. Type Symbol ID Obj Message
13 0 convention wrong-import-position C0413
Import "from blenderproc.scripts.visHdf5Files import vis_data" should be placed at the top of the module
14 0 convention wrong-import-position C0413
Import "from blenderproc.python.utility.Utility import Utility" should be placed at the top of the module

Module blenderproc.scripts.quickstart (blenderproc/scripts/quickstart.py)

Line Col. Type Symbol ID Obj Message
1 0 convention missing-module-docstring C0114
Missing module docstring
11 -1 warning pointless-string-statement W0105
String statement has no effect
13 0 convention wrong-import-position C0413
Import "import numpy as np" should be placed at the top of the module

Metrics

Count per types

Name Count
convention 61
refactor 3
warning 38

Count per messages

Name Count
trailing-whitespace 37
line-too-long 13
trailing-newlines 1
no-else-return 1
ungrouped-imports 1
unused-import 1
unidiomatic-typecheck 1
bad-indentation 13
self-assigning-variable 1
unused-variable 1
consider-using-augmented-assign 1
wrong-import-position 3
redefined-outer-name 4
protected-access 6
consider-using-with 1
global-variable-undefined 6
global-variable-not-assigned 5
wrong-import-order 4
missing-module-docstring 1
pointless-string-statement 1

Count per modules

Name Count
blenderproc 1
blenderproc.python.camera.CameraProjection 13
blenderproc.python.loader.CCMaterialLoader 1
blenderproc.python.loader.BopLoader 1
blenderproc.python.loader.BlendLoader 2
blenderproc.python.postprocessing.PostProcessingUtility 1
blenderproc.python.renderer.RendererUtility 3
blenderproc.python.types.EntityUtility 1
blenderproc.python.types.MeshObjectUtility 27
blenderproc.python.types.LightUtility 2
blenderproc.python.utility.InstallUtility 1
blenderproc.python.utility.Initializer 1
blenderproc.python.writer.GifWriterUtility 2
blenderproc.python.writer.BopWriterUtility 43
blenderproc.scripts.quickstart 3

Count per path

Name Count
blenderproc/__init__.py 1
blenderproc/python/camera/CameraProjection.py 13
blenderproc/python/loader/CCMaterialLoader.py 1
blenderproc/python/loader/BopLoader.py 1
blenderproc/python/loader/BlendLoader.py 2
blenderproc/python/postprocessing/PostProcessingUtility.py 1
blenderproc/python/renderer/RendererUtility.py 3
blenderproc/python/types/EntityUtility.py 1
blenderproc/python/types/MeshObjectUtility.py 27
blenderproc/python/types/LightUtility.py 2
blenderproc/python/utility/InstallUtility.py 1
blenderproc/python/utility/Initializer.py 1
blenderproc/python/writer/GifWriterUtility.py 2
blenderproc/python/writer/BopWriterUtility.py 43
blenderproc/scripts/quickstart.py 3
***The tests are done.*** Check the log:

Last update: 12/12/2024, 14:23:17

- Import `get_all_light_objects` and `convert_to_lights` in the
  lighting API.
- Move `get_all_blender_light_objects` to `BlenderUtility.py`.
- Remove duplicate `get_all_blender_light_objects` from
  `LightUtility.py`.
@cornerfarmer
Copy link
Member

cornerfarmer commented Dec 12, 2024

BlenderProcHelper result for run 638:

Done with: [amass_human_poses_python 31s, auto_shading_python 9s, basic_python 13s, blenderkit_python 21s, bop_object_on_surface_sampling_python 83s, bop_object_physics_positioning_python 114s, bop_object_pose_sampling_python 38s, bop_scene_replication_python 170s, camera_depth_of_field_python 20s, camera_object_pose_python 10s, camera_random_trajectories_python 60s, camera_sampling_python 20s, coco_annotations_python 15s, diffuse_color_image_python 25s, dust_python 19s, entity_displacement_modifier_python 16s, entity_manipulation_python 10s, front_3d_object_sampling_python 86s, front_3d_python 91s, front_3d_with_improved_mat_python 109s, git_log 1s, haven_python 24s, ikea_python 19s, kinect_azure_noise_python 14s, lens_distortion_python 16s, lens_distortion_python 13s, light_sampling_python 13s, material_manipulation_python 10s, material_randomizer_python 12s, matterport3d_python 66s, motion_blur_rolling_shutter_python 31s, motion_blur_rolling_shutter_python 31s, multi_render_python 288s, nocs_python 19s, object_pose_sampling_python 10s, on_surface_object_sampling_python 10s, optical_flow_python 28s, physics_convex_decomposition_python 130s, physics_positioning_python 24s, pix3d_python 17s, point_clouds_python 16s, random_backgrounds_python 19s, random_room_constructor_python 77s, replica_python 219s, scenenet_python 50s, scenenet_with_cctextures_python 63s, semantic_segmentation_python 13s, shapenet_python 19s, shapenet_with_scenenet_python 56s, shapenet_with_suncg_python 55s, spotlight_python 20s, stereo_matching_python 48s, stereo_matching_with_projector_python 148s, suncg_basic_python 34s, suncg_with_cam_sampling_python 57s, suncg_with_improved_mat_python 67s, suncg_with_object_replacer_python 59s, tests_python 29s, urdf_loading_and_manipulation_python 50s]
Done with 59 of 59 tests.
There were errors:
Unit tests output:

................
----------------------------------------------------------------------
Ran 16 tests in 24.036s

OK

urdf_loading_and_manipulation (main_python)

The output of urdf_loading_and_manipulation:main_python:000000_scene_gt_info_json has changed:

Expand
+ root['0'][2]['bbox_visib'][3]: 25
- root['0'][2]['bbox_visib'][3]: 23
+ root['1'][3]['bbox_visib'][3]: 79
- root['1'][3]['bbox_visib'][3]: 78

stereo_matching (main_python)

The output of stereo_matching:main_python:disparity has changed: Diff: 0.0323, Pixel diff: 0.0040



Compare image Newly generated image

stereo_matching_with_projector (main_python)

The output of stereo_matching_with_projector:main_python:disparity has changed: Diff: 0.0119, Pixel diff: 0.0056



Compare image Newly generated image

Pylint output

Expand

Messages

Module blenderproc (blenderproc/__init__.py)

Line Col. Type Symbol ID Obj Message
12 44 convention trailing-whitespace C0303
Trailing whitespace

Module blenderproc.python.camera.CameraProjection (blenderproc/python/camera/CameraProjection.py)

Line Col. Type Symbol ID Obj Message
4 0 warning unused-import W0611
Unused create_primitive imported from blenderproc.python.types.MeshObjectUtility
10 0 convention ungrouped-imports C0412
Imports from package blenderproc are not grouped
29 31 convention trailing-whitespace C0303
Trailing whitespace
35 0 convention trailing-whitespace C0303
Trailing whitespace
41 0 convention line-too-long C0301
Line too long (147/120)
85 8 refactor no-else-return R1705 depth_at_points_via_raytracing
Unnecessary "else" after "return", remove the "else" and de-indent the code inside it
89 0 convention trailing-whitespace C0303
Trailing whitespace
90 0 convention line-too-long C0301
Line too long (134/120)
141 0 convention trailing-whitespace C0303
Trailing whitespace
159 7 convention trailing-whitespace C0303
Trailing whitespace
161 33 convention trailing-whitespace C0303
Trailing whitespace
165 0 convention line-too-long C0301
Line too long (132/120)
167 0 convention trailing-newlines C0305
Trailing newlines

Module blenderproc.python.loader.BlendLoader (blenderproc/python/loader/BlendLoader.py)

Line Col. Type Symbol ID Obj Message
27 0 convention line-too-long C0301
Line too long (130/120)
100 0 convention trailing-whitespace C0303
Trailing whitespace

Module blenderproc.python.loader.BopLoader (blenderproc/python/loader/BopLoader.py)

Line Col. Type Symbol ID Obj Message
353 0 convention trailing-whitespace C0303
Trailing whitespace

Module blenderproc.python.loader.CCMaterialLoader (blenderproc/python/loader/CCMaterialLoader.py)

Line Col. Type Symbol ID Obj Message
73 0 convention line-too-long C0301
Line too long (152/120)

Module blenderproc.python.postprocessing.PostProcessingUtility (blenderproc/python/postprocessing/PostProcessingUtility.py)

Line Col. Type Symbol ID Obj Message
15 0 convention line-too-long C0301
Line too long (137/120)

Module blenderproc.python.renderer.RendererUtility (blenderproc/python/renderer/RendererUtility.py)

Line Col. Type Symbol ID Obj Message
246 0 convention trailing-whitespace C0303
Trailing whitespace
314 0 convention trailing-whitespace C0303
Trailing whitespace
504 0 convention trailing-whitespace C0303
Trailing whitespace

Module blenderproc.python.types.EntityUtility (blenderproc/python/types/EntityUtility.py)

Line Col. Type Symbol ID Obj Message
170 11 convention unidiomatic-typecheck C0123 Entity.duplicate
Use isinstance() rather than type() for a typecheck.

Module blenderproc.python.types.LightUtility (blenderproc/python/types/LightUtility.py)

Line Col. Type Symbol ID Obj Message
126 12 refactor consider-using-augmented-assign R6104 Light.setup_as_projector
Use '/=' to do an augmented assign directly
217 0 convention trailing-whitespace C0303
Trailing whitespace

Module blenderproc.python.types.MeshObjectUtility (blenderproc/python/types/MeshObjectUtility.py)

Line Col. Type Symbol ID Obj Message
520 87 convention trailing-whitespace C0303
Trailing whitespace
526 0 convention line-too-long C0301
Line too long (122/120)
529 0 convention trailing-whitespace C0303
Trailing whitespace
535 68 warning unused-variable W0612 MeshObject.add_auto_smooth_modifier
Unused variable 'data_from'
543 16 warning self-assigning-variable W0127 MeshObject.add_auto_smooth_modifier
Assigning the same variable 'modifier' to itself
545 0 convention trailing-whitespace C0303
Trailing whitespace
555 0 warning bad-indentation W0311
Bad indentation. Found 9 spaces, expected 8
559 0 convention trailing-whitespace C0303
Trailing whitespace
561 0 warning bad-indentation W0311
Bad indentation. Found 9 spaces, expected 8
562 0 convention trailing-whitespace C0303
Trailing whitespace
564 0 warning bad-indentation W0311
Bad indentation. Found 9 spaces, expected 8
566 0 warning bad-indentation W0311
Bad indentation. Found 13 spaces, expected 12
567 0 warning bad-indentation W0311
Bad indentation. Found 13 spaces, expected 12
568 0 warning bad-indentation W0311
Bad indentation. Found 13 spaces, expected 12
569 90 convention trailing-whitespace C0303
Trailing whitespace
569 0 warning bad-indentation W0311
Bad indentation. Found 13 spaces, expected 12
570 0 warning bad-indentation W0311
Bad indentation. Found 13 spaces, expected 12
571 0 warning bad-indentation W0311
Bad indentation. Found 13 spaces, expected 12
572 0 convention trailing-whitespace C0303
Trailing whitespace
573 23 convention trailing-whitespace C0303
Trailing whitespace
574 0 warning bad-indentation W0311
Bad indentation. Found 9 spaces, expected 8
576 0 warning bad-indentation W0311
Bad indentation. Found 9 spaces, expected 8
577 20 convention trailing-whitespace C0303
Trailing whitespace
578 0 warning bad-indentation W0311
Bad indentation. Found 9 spaces, expected 8
579 0 convention trailing-whitespace C0303
Trailing whitespace
580 0 warning bad-indentation W0311
Bad indentation. Found 9 spaces, expected 8
729 28 convention trailing-whitespace C0303
Trailing whitespace

Module blenderproc.python.utility.Initializer (blenderproc/python/utility/Initializer.py)

Line Col. Type Symbol ID Obj Message
80 0 convention trailing-whitespace C0303
Trailing whitespace

Module blenderproc.python.utility.InstallUtility (blenderproc/python/utility/InstallUtility.py)

Line Col. Type Symbol ID Obj Message
129 0 convention trailing-whitespace C0303
Trailing whitespace

Module blenderproc.python.writer.BopWriterUtility (blenderproc/python/writer/BopWriterUtility.py)

Line Col. Type Symbol ID Obj Message
9 0 convention wrong-import-order C0411
standard import "from typing import List, Optional, Dict, Tuple" should be placed before "import trimesh"
10 0 convention wrong-import-order C0411
standard import "import warnings" should be placed before "import trimesh"
11 0 convention wrong-import-order C0411
standard import "import datetime" should be placed before "import trimesh"
18 0 convention wrong-import-order C0411
standard import "import sys" should be placed before "import trimesh"
62 0 convention line-too-long C0301
Line too long (131/120)
80 8 warning redefined-outer-name W0621 write_bop
Redefining name 'dataset_objects' from outer scope (line 544)
175 12 warning protected-access W0212 write_bop
Access to a protected member _pyrender_init of a client class
177 0 convention line-too-long C0301
Line too long (124/120)
177 48 warning protected-access W0212 write_bop
Access to a protected member _pyrender_init of a client class
177 19 refactor consider-using-with R1732 write_bop
Consider using 'with' for resource-allocating operations
181 0 convention trailing-whitespace C0303
Trailing whitespace
187 0 convention trailing-whitespace C0303
Trailing whitespace
193 12 warning protected-access W0212 write_bop
Access to a protected member _pyrender_cleanup of a client class
313 21 warning redefined-outer-name W0621 _BopWriterUtility.get_frame_gt
Redefining name 'dataset_objects' from outer scope (line 544)
400 38 warning redefined-outer-name W0621 _BopWriterUtility.write_frames
Redefining name 'dataset_objects' from outer scope (line 544)
526 0 convention trailing-whitespace C0303
Trailing whitespace
538 78 convention trailing-whitespace C0303
Trailing whitespace
542 8 warning global-variable-undefined W0601 _BopWriterUtility._pyrender_init
Global variable 'renderer' undefined at the module level
542 8 warning global-variable-undefined W0601 _BopWriterUtility._pyrender_init
Global variable 'renderer_large' undefined at the module level
542 8 warning global-variable-undefined W0601 _BopWriterUtility._pyrender_init
Global variable 'dataset_objects' undefined at the module level
564 8 warning global-variable-undefined W0601 _BopWriterUtility._pyrender_cleanup
Global variable 'renderer' undefined at the module level
564 8 warning global-variable-undefined W0601 _BopWriterUtility._pyrender_cleanup
Global variable 'renderer_large' undefined at the module level
564 8 warning global-variable-undefined W0601 _BopWriterUtility._pyrender_cleanup
Global variable 'dataset_objects' undefined at the module level
570 0 convention line-too-long C0301
Line too long (173/120)
585 78 convention trailing-whitespace C0303
Trailing whitespace
591 8 warning global-variable-not-assigned W0602 _BopWriterUtility._calc_gt_masks_iteration
Using global for 'renderer' but no assignment is done
591 8 warning global-variable-not-assigned W0602 _BopWriterUtility._calc_gt_masks_iteration
Using global for 'dataset_objects' but no assignment is done
598 0 convention trailing-whitespace C0303
Trailing whitespace
689 0 convention line-too-long C0301
Line too long (165/120)
690 0 convention trailing-whitespace C0303
Trailing whitespace
693 0 convention line-too-long C0301
Line too long (196/120)
706 11 convention trailing-whitespace C0303
Trailing whitespace
708 78 convention trailing-whitespace C0303
Trailing whitespace
714 8 warning global-variable-not-assigned W0602 _BopWriterUtility._calc_gt_info_iteration
Using global for 'renderer_large' but no assignment is done
714 8 warning global-variable-not-assigned W0602 _BopWriterUtility._calc_gt_info_iteration
Using global for 'dataset_objects' but no assignment is done
714 8 warning global-variable-not-assigned W0602 _BopWriterUtility._calc_gt_info_iteration
Using global for 'renderer' but no assignment is done
718 11 warning protected-access W0212 _BopWriterUtility._calc_gt_info_iteration
Access to a protected member _renderer of a client class
719 12 warning protected-access W0212 _BopWriterUtility._calc_gt_info_iteration
Access to a protected member _renderer of a client class
720 12 warning protected-access W0212 _BopWriterUtility._calc_gt_info_iteration
Access to a protected member _renderer of a client class
727 0 convention trailing-whitespace C0303
Trailing whitespace
856 0 convention line-too-long C0301
Line too long (207/120)
857 0 convention trailing-whitespace C0303
Trailing whitespace
865 44 warning redefined-outer-name W0621 _BopWriterUtility.calc_gt_coco
Redefining name 'dataset_objects' from outer scope (line 544)

Module blenderproc.python.writer.GifWriterUtility (blenderproc/python/writer/GifWriterUtility.py)

Line Col. Type Symbol ID Obj Message
13 0 convention wrong-import-position C0413
Import "from blenderproc.scripts.visHdf5Files import vis_data" should be placed at the top of the module
14 0 convention wrong-import-position C0413
Import "from blenderproc.python.utility.Utility import Utility" should be placed at the top of the module

Module blenderproc.scripts.quickstart (blenderproc/scripts/quickstart.py)

Line Col. Type Symbol ID Obj Message
1 0 convention missing-module-docstring C0114
Missing module docstring
11 -1 warning pointless-string-statement W0105
String statement has no effect
13 0 convention wrong-import-position C0413
Import "import numpy as np" should be placed at the top of the module

Metrics

Count per types

Name Count
convention 61
refactor 3
warning 38

Count per messages

Name Count
trailing-whitespace 37
line-too-long 13
trailing-newlines 1
no-else-return 1
ungrouped-imports 1
unused-import 1
unidiomatic-typecheck 1
consider-using-augmented-assign 1
bad-indentation 13
self-assigning-variable 1
unused-variable 1
wrong-import-position 3
redefined-outer-name 4
protected-access 6
consider-using-with 1
global-variable-undefined 6
global-variable-not-assigned 5
wrong-import-order 4
missing-module-docstring 1
pointless-string-statement 1

Count per modules

Name Count
blenderproc 1
blenderproc.python.camera.CameraProjection 13
blenderproc.python.loader.CCMaterialLoader 1
blenderproc.python.loader.BopLoader 1
blenderproc.python.loader.BlendLoader 2
blenderproc.python.postprocessing.PostProcessingUtility 1
blenderproc.python.renderer.RendererUtility 3
blenderproc.python.types.EntityUtility 1
blenderproc.python.types.LightUtility 2
blenderproc.python.types.MeshObjectUtility 27
blenderproc.python.utility.Initializer 1
blenderproc.python.utility.InstallUtility 1
blenderproc.python.writer.GifWriterUtility 2
blenderproc.python.writer.BopWriterUtility 43
blenderproc.scripts.quickstart 3

Count per path

Name Count
blenderproc/__init__.py 1
blenderproc/python/camera/CameraProjection.py 13
blenderproc/python/loader/CCMaterialLoader.py 1
blenderproc/python/loader/BopLoader.py 1
blenderproc/python/loader/BlendLoader.py 2
blenderproc/python/postprocessing/PostProcessingUtility.py 1
blenderproc/python/renderer/RendererUtility.py 3
blenderproc/python/types/EntityUtility.py 1
blenderproc/python/types/LightUtility.py 2
blenderproc/python/types/MeshObjectUtility.py 27
blenderproc/python/utility/Initializer.py 1
blenderproc/python/utility/InstallUtility.py 1
blenderproc/python/writer/GifWriterUtility.py 2
blenderproc/python/writer/BopWriterUtility.py 43
blenderproc/scripts/quickstart.py 3
***The tests are done.*** Check the log:

Last update: 12/12/2024, 15:45:58

Copy link
Member

@cornerfarmer cornerfarmer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you looks good!

@cornerfarmer cornerfarmer merged commit 06b190f into DLR-RM:main Dec 12, 2024
2 checks passed
@hummat hummat deleted the extend_light branch December 12, 2024 17:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants