Roboflow model does not deploy to Oak D-Lite

I am trying to deploy my model to an OAK-D Lite, but when I execute my python script, I get the error message:

File "/Users/emmaiverson/Luxonis/depthai/legoExample/", line 8, in <module>
    rf = RoboflowOak(model="deccv3-vr35s", version="5", api_key="qp2BshcnAkF46Pg30wnP", confidence=0.05, overlap=0.5, rgb=True, depth=True, device=None, blocking=True)
  File "/Users/emmaiverson/Library/Python/3.10/lib/python/site-packages/roboflowoak/", line 34, in __init__
    self.size = (int(self.model_objects["environment"]["RESOLUTION"]), int(self.model_objects["environment"]["RESOLUTION"]))
TypeError: int() argument must be a string, a bytes-like object or a real number, not 'list'

Why am I getting this error in the file?
My python code:

from roboflowoak import RoboflowOak
import cv2
import time
import numpy as np

if __name__ == '__main__':
    # instantiating an object (rf) with the RoboflowOak module
    rf = RoboflowOak(model="deccv3-vr35s", version="5", api_key="XXX...XXX", confidence=0.05, overlap=0.5, rgb=True, depth=True, device=None, blocking=True)
    # Running our model and displaying the video output with detections
    while True:
        t0 = time.time()
        # The rf.detect() function runs the model inference
        result, frame, raw_frame, depth = rf.detect()
        predictions = result["predictions"]
        #    predictions:
        #    [ {
        #        x: (middle),
        #        y:(middle),
        #        width:
        #        height:
        #        depth: ###->
        #        confidence:
        #        class:
        #        mask: {
        #    ]
        #frame - frame after preprocs, with predictions
        #raw_frame - original frame from your OAK
        #depth - depth map for raw_frame, center-rectified to the center camera
        # timing: for benchmarking purposes
        t = time.time()-t0
        print("FPS ", 1/t)
        print("PREDICTIONS ", [p.json() for p in predictions])

        # setting parameters for depth calculation
        # comment out the following 2 lines out if you're using an OAK without Depth
        max_depth = np.amax(depth)
        cv2.imshow("depth", depth/max_depth)
        # displaying the video feed as successive frames
        cv2.imshow("frame", frame)
        # how to close the OAK inference window / stop inference: CTRL+q or CTRL+c
        if cv2.waitKey(1) == ord('q'):

I’m sorry, but your question seems to be incomplete. Could you please provide more details or context? Are you asking about how to create an Object Detection project on Roboflow, or are you asking about the system requirements for running Roboflow on a specific operating system? The more details you provide, the better I can assist you.

Hi! I’m Roboflow’s AI powered bot. This is an automated response powered using AI with knowledge from our docs, blog, and forum. If this solves your issue, please mark it as the solution using the checkbox icon. If this doesn’t solve your issue, please follow up with what you’ve tried/why, and the community will continue to chime in as usual.

Hi @emma-iverson ! It looks like we may have some out of date docs that lead you to using roboflowoak. The best route to follow is to use the official roboflow integration in the DepthAI package. You can follow this guide to see how that’s done: Deploy Models from Roboflow with the Luxonis DepthAI SDK

1 Like

Hi Paul, thank you for the reply. I re-downloaded depthai and followed the instructions for the M1 Macs. This is my updated code:

from depthai_sdk import OakCamera
import depthai

with OakCamera() as oak:
    color = oak.create_camera('color')
    model_config = {
        'source': 'roboflow', # Specify that we are downloading the model from Roboflow
    nn = oak.create_nn(model_config, color)
    oak.visualize(nn, fps=True)

However, I get this error message about not finding a URL:

➜ python3
Downloading ‘DECCv3’ model from Roboflow server
Closing OAK camera
Traceback (most recent call last):
File “/Users/emmaiverson/depthai/”, line 16, in
File “/Users/emmaiverson/Library/Python/3.10/lib/python/site-packages/depthai_sdk/”, line 286, in start # Build the pipeline
File “/Users/emmaiverson/Library/Python/3.10/lib/python/site-packages/depthai_sdk/”, line 380, in build
component.on_init(self._pipeline, self._oak.device, self._pipeline.getOpenVINOVersion())
File “/Users/emmaiverson/Library/Python/3.10/lib/python/site-packages/depthai_sdk/components/”, line 124, in on_init
path = self._roboflow.device_update(device)
File “/Users/emmaiverson/Library/Python/3.10/lib/python/site-packages/depthai_sdk/components/integrations/”, line 53, in device_update
File “/Users/emmaiverson/Library/Python/3.10/lib/python/site-packages/requests/”, line 953, in raise_for_status
raise HTTPError(http_error_msg, response=self)
requests.exceptions.HTTPError: 404 Client Error: Not Found for url:

Do you know why my model is not deploying to my Oak-D Lite?