Open SyedShafiq opened 2 months ago
Very sorry for your issues. parsing was indeed broken for ego road (for a subset of frames at least). This PR should fix it.
Thank you for your quick response. When can I expect it to be merged with the main branch?
This PR is now merged. If you are using the source code you can simply take down the latest changes! If you are using the pypi package, that will be updated later this week!
hi @SyedShafiq! could you please confirm if the PR resolved your issues so we could close this issue? thanks!
This is the error, encountered.
Exception has occurred: TypeError (note: full exception trace is shown but execution is paused at: _run_module_as_main)
'EgoRoadAnnotation' object is not iterable
File "D:\Thesis_Shafiq\Scene_Risk\Code\zodRepo\zod\utils\polygon_transformations.py", line 38, in polygons_to_binary_mask
for polygon in multi_polygon:
File "D:\Thesis_Shafiq\Scene_Risk\Code\zodRepo\examples\devkit_tutorialPy.py", line 322, in <module>
mask = polygons_to_binary_mask(polygon_annotations)
File "C:\Users\I010392\AppData\Local\Programs\Python\Python310\Lib\runpy.py", line 86, in _run_code
exec(code, run_globals)
File "C:\Users\I010392\AppData\Local\Programs\Python\Python310\Lib\runpy.py", line 196, in _run_module_as_main (Current frame)
return _run_code(code, main_globals, None,
TypeError: 'EgoRoadAnnotation' object is not iterable``
Upon debugging, there seems to be an error in this piece of code from polygin_transformations.py file:
def polygons_to_binary_mask(multi_polygons, img_shape=(2168, 3848)):
"""
Create binary mask for list of multi-polygons
"""
assert len(img_shape) == 2
mask = _create_image_mask(img_shape)
for multi_polygon in multi_polygons:
for polygon in multi_polygon:
mask += polygon_to_mask(polygon, img_shape, 1)
return mask.astype(bool)
You are right, the notebook still had issues with ego road annotations. Should be fixed here (also added another test to check for errors in the tutorial) https://github.com/zenseact/zod/commit/54c698d4e22c78013c522dc8e6d4409e1bf10f0f
Can you install/pull from latest master and try again? Sorry about the hassle
Hello,
I am encountering the following error: ValueError: 'RoadEdge_RaisedCurb' is not a valid EgoRoadClass
This is error is generated when I am running the following piece of code in devkit_tutorial.
Could you please suggest a workaround so that I can see the segmentation on the image? Seems like there are more than 2 classes in the EgoAnnotation data.