ModalAI Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Register
    • Login

    Masking qVio

    Ask your questions right here!
    2
    12
    765
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • D
      droen8
      last edited by

      Hi @Alex-Kushleyev,

      I am using ov7251 for tracking. I think I have made everything as described but it's still not working.

      https://ibb.co/XyDGG7w
      https://ibb.co/WkSDC2V
      https://ibb.co/6X5N6YV

      Regards

      Alex KushleyevA 1 Reply Last reply Reply Quote 0
      • Alex KushleyevA
        Alex Kushleyev ModalAI Team @droen8
        last edited by

        @droen8 , quick question, did you move the camera after starting vio or has it been stationary?

        Can you please try again by pointing the camera at a feature rich environment to make sure that top and bottom have many features and do not move the camera after you start qvio. I just want to double check.

        Also, something to check, if you provide an incorrect file name in qvio (or rename your mask), do you get a warning from qvio server saying that the file could not be loaded?

        Thanks

        Alex

        D 1 Reply Last reply Reply Quote 0
        • D
          droen8 @Alex Kushleyev
          last edited by droen8

          @Alex-Kushleyev
          Yes I have tried multiple times, the screenshoot was taken after few restarts of voxl-qvio-server. It's for sure not using a mask.
          I have tried renaming mask and I have not seen any errors when mask do not exist in provided path. I have tried to display printf("Mask file name = %s \n", staticMaskFileName); in _hard_reset function and the path is displayed properely. I do not have idea how can I debug this issue.

          With existing file in mask_file_path:
          1677ac82-4c41-4957-bac1-0ec6cb3ba1b7-image.png

          Renamed file:
          a504e4a8-c563-44b3-a8cb-8b9b29210c92-image.png

          After renaming to ...maskWrongFilename.pgm :
          4d31af1b-06ac-4d69-af1e-b7a8f64b60b5-image.png

          Alex KushleyevA 1 Reply Last reply Reply Quote 0
          • Alex KushleyevA
            Alex Kushleyev ModalAI Team @droen8
            last edited by

            @droen8 , i believe there is a special command that silences the output of QVIO during initialization:

            https://gitlab.com/voxl-public/voxl-sdk/services/voxl-qvio-server/-/blob/master/server/main.cpp?ref_type=heads#L368

            Please try to remove that wrapper SILENT_STD around the mvVISLAM_Initialize call and see if you get any messages about the mask file (when it has correct or incorrect file name).

            Sorry, there is no good way to debug this, but hopefully this will provide more information.

            Alex

            D 1 Reply Last reply Reply Quote 0
            • D
              droen8 @Alex Kushleyev
              last edited by

              @Alex-Kushleyev thank you, I have not noticed that init function is wrapped. Now I can see that path is relative to /home/root

              14be1cd5-54a3-46d1-949c-750cf2fac0f4-image.png

              I will try in few if it's working but it will for sure 🙂 There is another error with Configuration.SF.xml should I have It in mind?

              Alex KushleyevA D 2 Replies Last reply Reply Quote 0
              • Alex KushleyevA
                Alex Kushleyev ModalAI Team @droen8
                last edited by

                @droen8 ,

                Oh yes... you found the issue.

                I believe the other error (Configuration.SF.xml) is OK, we never used that file, so the configuration is passed via the mvVISLAM_Initialize call.

                I'll discuss with the team how to fix this path issue for the mask file

                Alex

                D 1 Reply Last reply Reply Quote 0
                • D
                  droen8 @droen8
                  last edited by droen8

                  This post is deleted!
                  1 Reply Last reply Reply Quote 0
                  • D
                    droen8 @Alex Kushleyev
                    last edited by

                    @Alex-Kushleyev It is not complaining about mask opening fail now but It is still not working:
                    fe72148b-20de-4a91-a7d6-b7fd95640f04-image.png
                    Voxl is stationary and I have tried reseting qvio:
                    852face3-0e7c-4cc7-92f7-4e88f50d243f-image.png

                    //edit the relativity of a path was due to me running voxl-qvio-server from there. When I run It as a service It is using absolute paths now. But still not working with repository example mask nor with my own mask.
                    4d59b0af-23dc-4a77-9ddb-97554fd1a580-image.png

                    Alex KushleyevA 1 Reply Last reply Reply Quote 0
                    • Alex KushleyevA
                      Alex Kushleyev ModalAI Team @droen8
                      last edited by

                      @droen8 , it looks like the mask file that I shared is not working. I did some digging and found that there is a formatting issue. if you open the pgm file with vi, you can see:

                      P5 160 120 255
                      ^@^@^@^@^@^@^@^@...
                      

                      but it should be:

                      P5
                      #
                      160 120
                      255
                      ^@^@^@^@^@^@^
                      

                      I am not sure how this happened.

                      I used vi to fix the sample mask, can you please try it? https://storage.googleapis.com/modalai_public/temp/voxl2-misc-packages/mask_example_160x120_fixed.pgm . Also, can you inspect the mask that you created? The PGM file should have the header above and then 8-bit mask entries where white (255) being where NO features should be found and black (0) where ok to have features.

                      Alex

                      D 1 Reply Last reply Reply Quote 0
                      • D
                        droen8 @Alex Kushleyev
                        last edited by

                        @Alex-Kushleyev said in Masking qVio:

                        P5

                        160 120
                        255
                        ^@^@^@^@^@^@^

                        It is working now thanks. I have created mask in monochrome bmp and then used online tool to convert it into pgm but output had wrong header:

                        P5
                        160 120
                        1
                        ^@^@^@^@^@^@^
                        

                        I have used gimp now and exported with .pgm (binary) and it's working 😄

                        I put a preview mask on output image.
                        d4604289-19d3-462f-99e3-89dcc788282c-image.png

                        1 Reply Last reply Reply Quote 0
                        • Alex KushleyevA Alex Kushleyev referenced this topic on
                        • Gary HolmgrenG Gary Holmgren referenced this topic on
                        • Gary HolmgrenG Gary Holmgren referenced this topic on
                        • Alex KushleyevA Alex Kushleyev referenced this topic on
                        • First post
                          Last post
                        Powered by NodeBB | Contributors