Blob data out inconsistencies

  • Hi,


    I'm developing an applet that will take in a 8k x 10k image, and look for blobs. The blobs that are detected below a certain size are filtered out, and the remaining blobs are then structured as 16-bits bitwise across two 8-bit pixels and then inserted together to create a 2 x 6 image for each blob looking like this:


    pasted-from-clipboard.png


    This is working great in simulation, however when I synthesize this for a mE5-VCL board I get all the values arranged across a single line with the rest of the values as zero like this:


    pasted-from-clipboard.png


    I'm not quite sure why there's a difference between simulation and synthesis.


    Would anyone be able to have a look and offer any ideas?


    Many thanks,


    Aaron

  • Hi Aaron,


    I think you only got a disply issue.

    You could either configure microDisplay via FG_WIDTH and FG_HEIGHT to the dimensions you desire or you could set the max-Dimensions to the values. You have set it to 8Kx6. This means microDisplay expects the image to be of this size and sets the dimensions accordingly.

    To avoid that you can use SetDimension in between your Blob_Analysis Box and the BlobOutput.


    Best regards,

    Björn

  • Hi Aron


    a DMA transfer will always discard the line length information. The software application needs to know about the image dimensions and pixel format of the transferred image. microDisplay will use the link properties of the VisualApplets design to get these information.

    In your case you used SetDimension and defined the output format to 8192 x 6 @ 8 bit.

    pasted-from-clipboard.png


    If you change the dimensions to 2 x 65536 microDisplay will display your results as you need.

    pasted-from-clipboard.png

    Note that this change does not change anything in the implementation or DMA transfer. It is just the way microDisplay will show the DMA result. The number of byte of the transfer are the same.


    Johannes


    Johannes Trein
    Teamleader Applications and Development
    SiliconSoftware GmbH
    https://silicon.software/wp-content/uploads/siso-logo-animation.gif



  • Hi Johannes,


    You're right. Changing the link to 2x65536 places the blob order correctly in the case of a single blob. What would be the best way to organise the blob data stream for microDisplay to show the data in 2x6 format side by side like so? I would like to add this data to the bottom of the original image in this format. The number of blobs detected for each image will vary.


    pasted-from-clipboard.png

  • Hi Aron,


    microDisplay can only display images having the same line length. It will be the one you define in the DmaToPC operator and will be by default the link properties.

    The only chance you have is to expand the line length of the blob output to the line length of the image. However this will generate an enormous data overhead in the DMA transfer. I do not recommend this solution.

    Anyway for demo purposes in microDisplay it might be OK. See the attachment

    pasted-from-clipboard.png


    Johannes

    Files


    Johannes Trein
    Teamleader Applications and Development
    SiliconSoftware GmbH
    https://silicon.software/wp-content/uploads/siso-logo-animation.gif



  • Hi Johannes,


    Many thanks for the help, I'll check this out. I think I was attempting to embed the blob data in an empty image using CreateBlank Image in a previous iteration, but I wasn't doing it like your example.


    Best regards,


    Aaron