Hello, I'm a computer engineer student and I'm totally new to this stuff

I have bought a Luxonis Oak-D camera and I have downloaded the required libraries and run the camera and it worked.

I have a project that needs to identify the dates that walk on the Conveyor Belts and calculate the length and width for each one, but it seems that it cannot recognize the fruits and I do not know what to do. Can you help me?

    Hi Manar
    In order to recognize the dates, you will need a neural network model that is able to detect a date on the image frame. To do that, I suggest looking at this guide: https://pyimagesearch.com/2021/11/01/training-an-object-detector-from-scratch-in-pytorch/

    You will need labelled images of dates as training set. More should be explained in the guide anyway.

    The .pt file you get after you have created the model should first be converted to ONNX, and then you can use our https://blobconverter.luxonis.com to convert your model to .blob, which can be run on the OAK device.

    This is a detection model, meaning it will output a bounding box coordinates for a detected date. If you explicitly need the width and the height and the dates come in all sorts of orientations on the conveyor belt, then you could opt into a segmentation model to achieve that. But let's start easy.

    Thanks,
    Jaka

      jakaskerl thank you jaka for your replying
      It seems that I made a mistake in something. I don't want to do machine learning on dates, because this is a little difficult for me. I just want it to calculate the length and width of the date. There is no need to make it know that it is a date. Is this possible?

        Hi Manar
        You will need a way to detect dates, that's why I suggested ML. Since you are also using OAK devices, I thought you could leverage the computation power of dedicated hardware to speed up the AI interference. But ok, without ML.


        To measure the dates, you need to know their positions on the image frame. A non ml option would be to have them on a highly contrasting background (eg. the conveyor belt is white). Then you would perform segmentation by basically grouping same colored pixels together to create blobs which would represent dates. Then you could apply an algorithm that would find the orientation and dimensions of each date.

        In this case, your oak device would basically work as a normal camera since all processing would run on the host machine. You wouldn't be using depth either (or perhaps you could to aid in detection).

        Thoughts?
        Jaka