Search found 2710 matches

by kwagyeman
Mon Jan 14, 2019 2:43 am
Forum: Technical Discussion
Topic: How can I find minimum area rectangle in binary image?
Replies: 17
Views: 3338

Re: How can I find minimum area rectangle in binary image?

Hi, I'm still working on the min_area_rect() method. The method I used doesn't seem to work in all situations. It's very memory intensive to store the contour and then calculate the min_area_rect() per frame based on a full contour of the object. I am trying to figure out a way to do this with just ...
by kwagyeman
Mon Jan 14, 2019 1:11 am
Forum: General Topics
Topic: Pricing
Replies: 1
Views: 1220

Re: Pricing

About $3. It's cheaper if you buy questionable versions in China. Lots of random other parts make the whole assembly higher priced.
by kwagyeman
Sun Jan 13, 2019 11:15 pm
Forum: General Topics
Topic: margin in for loop of color tracking
Replies: 1
Views: 1202

Re: margin in for loop of color tracking

Hi, it just controls how how much distance blobs need to be away before they are merged. By default it is 0 meaning that unless blobs have overlapping rects they will not be merged. With a value of 10 it means that blobs that overlap within 10 pixels of each other will be merged. With -10 it means t...
by kwagyeman
Sun Jan 13, 2019 5:28 pm
Forum: General Topics
Topic: Sleep mode
Replies: 5
Views: 1502

Re: Sleep mode

Yeah, you can sleep the camera too.
by kwagyeman
Sat Jan 12, 2019 12:49 pm
Forum: Technical Discussion
Topic: image drawstring() landscape orientation (or image rotation function)?
Replies: 3
Views: 1313

Re: image drawstring() landscape orientation (or image rotation function)?

Hi, the latest firmware build offers vertical and horizontal mirroring along with image rotation. This does exactly what you want. # Vertical Flip - Horizontal Mirror - Transpose # # This example shows off how to vertically flip, horizontally mirror, or # transpose an image. Note that: # # vflip=Fal...
by kwagyeman
Sat Jan 12, 2019 12:45 pm
Forum: General Topics
Topic: Outsourcing project development
Replies: 1
Views: 1243

Re: Outsourcing project development

Good luck finding help.
by kwagyeman
Sat Jan 12, 2019 12:44 pm
Forum: General Topics
Topic: Shape Detection
Replies: 18
Views: 4825

Re: Shape Detection

Do something like this: import sensor, image, time # Color Tracking Thresholds (L Min, L Max, A Min, A Max, B Min, B Max) thresholds = [(30, 100, 15, 127, 15, 127)] sensor.reset() sensor.set_pixformat(sensor.RGB565) sensor.set_framesize(sensor.QVGA) sensor.skip_frames(time = 2000) sensor.set_auto_ga...
by kwagyeman
Sat Jan 12, 2019 12:06 pm
Forum: Technical Discussion
Topic: Literacy Project
Replies: 5
Views: 1223

Re: Literacy Project

Hi, you can't use input() with the IDE. We have no support for text transport to the camera. You can do this outside of the IDE however.
by kwagyeman
Fri Jan 11, 2019 12:09 pm
Forum: Technical Discussion
Topic: QUESTION ABOUT I2C CONNECTION
Replies: 4
Views: 1284

Re: QUESTION ABOUT I2C CONNECTION

Hi, you need pull up resistors on the I2C lines. The OpenMV Cam doesn't pull the lines up by default. I2C Scan should work once you do that.
by kwagyeman
Fri Jan 11, 2019 12:03 pm
Forum: Technical Discussion
Topic: Communication between OpenMV and ROS
Replies: 3
Views: 1156

Re: Communication between OpenMV and ROS

Would you like this to be distributed with OpenMV IDE? It will get more usage then.
by kwagyeman
Fri Jan 11, 2019 3:17 am
Forum: Technical Discussion
Topic: Second SPI device while using LCD shield?
Replies: 12
Views: 1839

Re: Second SPI device while using LCD shield?

It's on my todo list. I'm doing imglib expansion right now. Currently working on adding a lot of features to find_blobs() so it's at rough and exceeding parity with OpenCV.
by kwagyeman
Fri Jan 11, 2019 2:45 am
Forum: General Topics
Topic: LED Selection not working as doccumented
Replies: 18
Views: 3338

Re: LED Selection not working as doccumented

Well, our firmware definitely toggles the pins for all parts of the LED. The only thing I can guess is that the LED uses was the wrong type ending up with the anode/cathodes on the wrong pins. The LED we use is kinda tricky to get right. Our CM seems to find the right one however so we don't think a...
by kwagyeman
Thu Jan 10, 2019 11:46 pm
Forum: General Topics
Topic: OpenMV as Slave + Data received from Arduino
Replies: 7
Views: 1476

Re: OpenMV as Slave + Data received from Arduino

If using blue tooth uarts. Sure.
by kwagyeman
Thu Jan 10, 2019 11:16 pm
Forum: General Topics
Topic: OpenMV as Slave + Data received from Arduino
Replies: 7
Views: 1476

Re: OpenMV as Slave + Data received from Arduino

Keep in mind that the Serial debug port on a UNO isn't usable if you are using the Arduino's UART for the OpenMV Cam. So, use Software serial to communicate with the OpenMV Cam so you can still deubg.
by kwagyeman
Thu Jan 10, 2019 11:07 pm
Forum: Technical Discussion
Topic: how to send image to server by post to http?
Replies: 9
Views: 1842

Re: how to send image to server by post to http?

Ibrahim will have to answer this. The WiFi part I'm not strong with.
by kwagyeman
Thu Jan 10, 2019 11:05 pm
Forum: General Topics
Topic: LED Selection not working as doccumented
Replies: 18
Views: 3338

Re: LED Selection not working as doccumented

That's definitely a clone board if you bought it from Banggood.

Um, so, are you running the latest firmware? There was a swap a long time ago between the green and blue led pins that was fixed by a software update.
by kwagyeman
Thu Jan 10, 2019 11:03 pm
Forum: General Topics
Topic: OpenMV as Slave + Data received from Arduino
Replies: 7
Views: 1476

Re: OpenMV as Slave + Data received from Arduino

Hi, the OpenMV Cam makes a very poor I2C slave or SPI slave. This is because it needs to generally do other things than wait for the Arduino to command it. UART is the only thing that works well. If possible, make your Arduino a UART slave I/O extender for the OpenMV Cam. I am also working on a CAN ...
by kwagyeman
Thu Jan 10, 2019 3:49 pm
Forum: General Topics
Topic: store an image on sd card
Replies: 1
Views: 1231

Re: store an image on sd card

Do something like "/file.jpg".
by kwagyeman
Thu Jan 10, 2019 3:18 pm
Forum: Technical Discussion
Topic: Finding Circle and Color Detection
Replies: 3
Views: 1178

Re: Finding Circle and Color Detection

Hi, okay, 640x480 runs at 20 fps actually if only using find_blob() in grayscale. If you are in RGB565 it's slower. Keep in mind that the frame buffer display cuts the frame rate. So, if you click the disable frame buffer button in the IDE you will see your FPS jump. This is the frame rate your actu...
by kwagyeman
Thu Jan 10, 2019 3:09 pm
Forum: Technical Discussion
Topic: mjpeg video code
Replies: 9
Views: 1693

Re: mjpeg video code

We had to read the spec and then figure it out...
by kwagyeman
Thu Jan 10, 2019 12:04 pm
Forum: Technical Discussion
Topic: mjpeg video code
Replies: 9
Views: 1693

Re: mjpeg video code

Yeah, the bbp means different things at different times. If the value is >= 4 then it's actually the file length in bytes of a jpg image. Yes, this is poor design but it works and it's so built-into the logic now that its a bear to change.
by kwagyeman
Thu Jan 10, 2019 12:03 pm
Forum: Technical Discussion
Topic: how to send image to server by post to http?
Replies: 9
Views: 1842

Re: how to send image to server by post to http?

Hi, use this to encode:

http://docs.micropython.org/en/v1.9.3/p ... ascii.html

And call .compress() on the image to get a jpeg byte stream.

E.g.

Code: Select all

base63_data = ubinascii.b2a_base64(img.compress(quality=90))
Then transmit that data.
by kwagyeman
Thu Jan 10, 2019 12:01 pm
Forum: Technical Discussion
Topic: How can I find minimum area rectangle in binary image?
Replies: 17
Views: 3338

Re: How can I find minimum area rectangle in binary image?

Hi, I recently updated the firmware method with a major_axis_line() method that will tell you the longest length of the side in the min_area_rect. So, that's basically what you need. As for transmit via the UART. See the UART example on our docs. You can just print the value. I'll upload the new fir...
by kwagyeman
Thu Jan 10, 2019 11:55 am
Forum: Technical Discussion
Topic: Finding Circle and Color Detection
Replies: 3
Views: 1178

Re: Finding Circle and Color Detection

Hi, we can't process a VGA image with all the algorithms. Please keep in mind you are using a microcontroller with only 512KB of RAM onboard and not a full linux system with GBs of RAM. find_blobs() works on a VGA image. But, it's rather slow since there's so many pixels to process. Unless you need ...
by kwagyeman
Wed Jan 09, 2019 2:29 pm
Forum: Technical Discussion
Topic: mjpeg video code
Replies: 9
Views: 1693

Re: mjpeg video code

The write data method writes the data. It's a byte blob so you just give the starting address and length. As for the jpeg compression that's done in the jpeg compression call.
by kwagyeman
Wed Jan 09, 2019 2:27 pm
Forum: Project Discussion
Topic: nn_cifar10
Replies: 10
Views: 2591

Re: nn_cifar10

Yes, please read the guide linked to above in a previous post. It's quite detailed.
by kwagyeman
Wed Jan 09, 2019 11:29 am
Forum: General Topics
Topic: find real x and y coordinates of an object
Replies: 9
Views: 1078

Re: find real x and y coordinates of an object

Okay, use the cx() and cy() properites of find_blobs() which I noticed you are using in another forum post.
by kwagyeman
Wed Jan 09, 2019 11:28 am
Forum: Technical Discussion
Topic: Implementing low-cost pre-trained NN like MobileNet/SqueezeNet
Replies: 11
Views: 1422

Re: Implementing low-cost pre-trained NN like MobileNet/SqueezeNet

I haven't looked at this in a few months. I don't know if it works or not.
by kwagyeman
Wed Jan 09, 2019 11:27 am
Forum: Project Discussion
Topic: nn_cifar10
Replies: 10
Views: 2591

Re: nn_cifar10

It means the network is too big. So, you need to reduce the net size. The M7 doesn't really have enough heap ram to run larger nets.
by kwagyeman
Wed Jan 09, 2019 3:03 am
Forum: Technical Discussion
Topic: Implementing low-cost pre-trained NN like MobileNet/SqueezeNet
Replies: 11
Views: 1422

Re: Implementing low-cost pre-trained NN like MobileNet/SqueezeNet

We really can use all the help we can get with the OpenMV Cam project. If you'd like to try to make an SDRAM version of the board please go ahead. As for the INRIA model. I think we fixed the issue with the system. I just haven't had time to revisit it. I'm in the middle of doing library upgrades ri...
by kwagyeman
Wed Jan 09, 2019 2:32 am
Forum: General Topics
Topic: color sensor
Replies: 3
Views: 887

Re: color sensor

Hi, if you need to detect the depth you can do two things: 1. You can use the number of pixels/area of the object as an input into a look-up table where you've recorded the depth of the object given some pixel/area values. That said, this method isn't exactly precise but works without any external s...
by kwagyeman
Wed Jan 09, 2019 2:31 am
Forum: General Topics
Topic: area threshold and pixel threshold
Replies: 1
Views: 718

Re: area threshold and pixel threshold

Area threshold is a threshold bases on the area (w*h) of the object versus the pixel threshold is based on the number of pixels in it. If you look at the ratio (density) of the two you can get some idea how good your lock on the object is because the number of pixels should area be near the area for...
by kwagyeman
Wed Jan 09, 2019 2:28 am
Forum: General Topics
Topic: find real x and y coordinates of an object
Replies: 9
Views: 1078

Re: find real x and y coordinates of an object

How do you plan to track the object? By what feature?
by kwagyeman
Wed Jan 09, 2019 2:27 am
Forum: Technical Discussion
Topic: Implementing low-cost pre-trained NN like MobileNet/SqueezeNet
Replies: 11
Views: 1422

Re: Implementing low-cost pre-trained NN like MobileNet/SqueezeNet

Hi, if you want to develop a board design that does that can you do so. We don't have external RAM on board because it would be cost-prohibitive. External SDRAM would take an 8-layer board, require a smaller form factor H7 chip, and a host of other things. The H7 (our next system) is actually a lot ...
by kwagyeman
Tue Jan 08, 2019 11:35 pm
Forum: Technical Discussion
Topic: mjpeg video code
Replies: 9
Views: 1693

Re: mjpeg video code

Ha, that codes is wrong 3 years ago. I don't know who wrote that... wait, I did :). Um, the bpp field is the length of the jpeg file in bytes when >= 4. It's a rather abused value. Anyway, the jpeg data byte stream must be a multiple of 4. The reading past okay comment there notes that I'm writing g...
by kwagyeman
Tue Jan 08, 2019 2:57 am
Forum: General Topics
Topic: Use FLIR Lepton and Camera toghether on one module
Replies: 17
Views: 946

Re: Use FLIR Lepton and Camera toghether on one module

Hi, for various reasons it's actually extremely hard to make the FLIR Lepton 3 work with any MCU. The device has silicon bugs in it that cause it to crash if not clocked by SPI constantly. Then given it's weird vospi protocol we had to write a very *creative* driver solution to pull data from it wit...
by kwagyeman
Tue Jan 08, 2019 12:01 am
Forum: General Topics
Topic: color sensor
Replies: 3
Views: 887

Re: color sensor

The OV7725?
by kwagyeman
Mon Jan 07, 2019 11:59 pm
Forum: General Topics
Topic: maintaing same brightness throughout video
Replies: 13
Views: 1979

Re: maintaing same brightness throughout video

Hi, the OV7725?
by kwagyeman
Mon Jan 07, 2019 4:11 am
Forum: Technical Discussion
Topic: How can I find minimum area rectangle in binary image?
Replies: 17
Views: 3338

Re: How can I find minimum area rectangle in binary image?

Hi, okay, I did it. Attached is the new firmware. Here's some sample code: # Single Color RGB565 Blob Tracking Example # # This example shows off single color RGB565 tracking using the OpenMV Cam. import sensor, image, time, math threshold_index = 0 # 0 for red, 1 for green, 2 for blue # Color Track...
by kwagyeman
Mon Jan 07, 2019 2:55 am
Forum: General Topics
Topic: Shape Detection
Replies: 18
Views: 4825

Re: Shape Detection

Hi, if the rectangles are in a row in the x direction you just need to sort the rectangle objects by their x positions and then pick the 4th one from the list if it exist. You can use the sorted() method in MicroPython to sort the list and you can set the key for sorting to be equal to the x value o...
by kwagyeman
Sun Jan 06, 2019 8:44 pm
Forum: Technical Discussion
Topic: How to measure volume of objects with irregular shapes
Replies: 16
Views: 836

Re: How to measure volume of objects with irregular shapes

Okay, it's done. Just add x_hist_bins_max=<a number> and y_hist_bins_max=<a number> to find_blobs(). Then you can get the histogram list via the x_hist_bins() and y_hist_bins() properties. X and Y are completely separate. So, enable one, or the other, or both. The returned value above is a python li...
by kwagyeman
Sun Jan 06, 2019 3:59 pm
Forum: General Topics
Topic: face_recognition.py example not working
Replies: 10
Views: 2782

Re: face_recognition.py example not working

K, I'll get this fixed for the next firmware release.
by kwagyeman
Sun Jan 06, 2019 3:58 pm
Forum: Technical Discussion
Topic: Communication between OpenMV and ROS
Replies: 3
Views: 1156

Re: Communication between OpenMV and ROS

Hi, you'd need to write a ROS node that receives serial data from a serial port and publishes the messages in ROS. In python code this isn't really a lot of lines. Keep in mind the OpenMV Cam isn't a fixed function sensor where there's an obvious way to do this. You can design whatever application y...
by kwagyeman
Sat Jan 05, 2019 6:03 pm
Forum: Technical Discussion
Topic: How to measure volume of objects with irregular shapes
Replies: 16
Views: 836

Re: How to measure volume of objects with irregular shapes

Okay. I'll add the binary image projections: http://www.cse.usf.edu/~r1k/MachineVisionBook/MachineVision.files/MachineVision_Chapter2.pdf For both w and h. I can allocate an array that's static for the width and height of the image and the accumulate into both. Then, after the accumulation I can fin...
by kwagyeman
Sat Jan 05, 2019 2:11 pm
Forum: Technical Discussion
Topic: How to measure volume of objects with irregular shapes
Replies: 16
Views: 836

Re: How to measure volume of objects with irregular shapes

Mmm, number of pixels in every column is a reduction. That's kinda doable. It's still a lot of RAM however. Please work on the full algorithm and see if we can get more reductions. I can do like a flag which would enable population of an array value otherwise which would be null if the flag isn't pa...
by kwagyeman
Sat Jan 05, 2019 2:09 pm
Forum: Technical Discussion
Topic: How to measure volume of objects with irregular shapes
Replies: 16
Views: 836

Re: How to measure volume of objects with irregular shapes

Um, can you write the code you need to parase that pixel array you talked about and I'll see what I can put in the C code. I understand you need two cameras and have to take a view into account. However, if you do rotation correction on each cameras image then that removes that variable. So, then yo...
by kwagyeman
Sat Jan 05, 2019 1:41 pm
Forum: Technical Discussion
Topic: How to measure volume of objects with irregular shapes
Replies: 16
Views: 836

Re: How to measure volume of objects with irregular shapes

Hi, I can't expose that because of how much RAM it would take. I can only expose a mathematical derivative of the pixels inside of the blob. Please try to work out what mathematical operation you need done and then I can implement it in C code. Please keep in mind that memory on the microcontrollers...
by kwagyeman
Sat Jan 05, 2019 12:32 pm
Forum: Project Discussion
Topic: Open Mv face_detection over wifi
Replies: 13
Views: 1256

Re: Open Mv face_detection over wifi

Hi, you haven't described what application is receiving your data. A socket has to connect to some device and send the data to it. If you want to do a WiFi based application you need to think about what will receive the data and clearly define a protocol for that reception.

Go to advanced search