luxonis / depthai-experiments

Experimental projects we've done with DepthAI.
MIT License
809 stars 362 forks source link

error running `gen2-record-replay` #404

Closed orgicus closed 1 year ago

orgicus commented 1 year ago

Hi,

I've recently setup a virtual environment using Python 3.9.7 (64bit) on Windows (11) with the recommended version of dependencies. (I spotted the depthaisdk version was bumped up literary hours ago :) nice work @Erol444 !)

This is the error I'm encountering:

python record.py -p test2.bag -save depth
Found 1 devices
Traceback (most recent call last):
  File "C:\Users\george.profenza\Documents\gp\depthai-experiments\gen2-record-replay\record.py", line 145, in <module>
    run()
  File "C:\Users\george.profenza\Documents\gp\depthai-experiments\gen2-record-replay\record.py", line 95, in run
    recording.start() # Start recording
  File "C:\Users\george.profenza\Documents\gp\depthai-2022\env\lib\site-packages\depthai_sdk\record.py", line 132, in start
    self.pipeline, self.nodes = self._createPipeline()
  File "C:\Users\george.profenza\Documents\gp\depthai-2022\env\lib\site-packages\depthai_sdk\record.py", line 280, in _createPipeline
    nodes['stereo'] = self.pm.createDepth(control=False, pipeline=pipeline, args = self.args)
  File "C:\Users\george.profenza\Documents\gp\depthai-2022\env\lib\site-packages\depthai_sdk\managers\pipeline_manager.py", line 391, in createDepth
    return self.createDepth(
  File "C:\Users\george.profenza\Documents\gp\depthai-2022\env\lib\site-packages\depthai_sdk\managers\pipeline_manager.py", line 422, in createDepth
    self.nodes.stereo.setOutputSize(*self.nodes.camRgb.getPreviewSize())
AttributeError: 'types.SimpleNamespace' object has no attribute 'camRgb'

What can I try to avoid the error and recorg a .bag file ?

Thank you so much, George

Erol444 commented 1 year ago

Sorry about the delay @orgicus , looking into it now..

Erol444 commented 1 year ago

@orgicus you can do pip install depthai_sdk/ on branch linked from the PR I created (Fix sdk) and try again. Thanks, Erik

orgicus commented 1 year ago

Hi @Erol444 ,

Apologies for the delayed reponse. I can confirm with your fixes, depth gets recorded to .bag format. Thank you so much!