temporalecologylab / TreeRings

Project developing methods and tools needed to collect tree ring dendrology data
2 stars 0 forks source link

Cheap camera with C-mount lens #2

Closed afong3 closed 2 months ago

afong3 commented 1 year ago

Summary

Budget camera option by taking C mount lenses commonly used for CCTV or machine vision applications.

Benefits:

  1. Seemingly requires less frame height to get appropriately framed images than a handheld camera
  2. A lighter camera will have less frame shake
  3. Experimenting with various C-mount lenses will not be catastrophic to the budget
  4. Camera mount does not need to fit a wide variety of handheld cameras
  5. More budget friendly

Drawbacks:

  1. Potentially worse overall image quality
  2. Likely will require more images to stitch together than a better camera with a wider field of view and equal resolution
  3. No autofocus if the core is not flat

Rough Field of View Calculations

Although it is not a subsitute for testing the camera and lens to verify the details of the sample is sufficient, I've included some rough calculations of field of view for camera and lens combinations. I reckon that this can be used as an estimate for how detailed of an image we will be able to capture.

Link

Examples of Images:

(NOTE: they are using a 300x macro lens which I have not been able to find in stock) Shortcut to video slideshow of cells, rulers, PCB's, etc.

lizzieinvancouver commented 1 year ago

@afong3 Thanks for your work on this! If there's anything we need to buy in the US, let me know. I can order and bring back a few things -- though nothing too giant as I am already transporting a lot of tree cores.

DeirdreLoughnan commented 11 months ago

@afong3 @soleil-nocturne123

I took some images of a sanded cookies using a pi camera and a 180x lens using a 12MP sensor, just to get a sense of how well this will work. Also please ignore the scratches, we will get better at sanding with practice!

I think the camera set up works, but we would want an even better lens, and we could get up to 300x.

Screen Shot 2023-12-07 at 11 24 24 PM
lizzieinvancouver commented 11 months ago

@DeirdreLoughnan This is awesome! Have i mentioned how excited I am? I am.

afong3 commented 11 months ago

@DeirdreLoughnan this is very cool! Are you able to save them as .raw images? Also do you know the measured height and width that are in frame?

afong3 commented 8 months ago

I've done some testing with the two lenses we have for the Raspberry Pi HQ camera. Some input would be great to see if we need any higher level of magnification or not. The images are slightly out of focus because the camera mount I am using is a bit finicky.

Camera Lens Image
Raspberry Pi HQ Camera SEEED Studio 300x Lens IMG-20240308-WA0003
Raspberry Pi HQ Camera SEEED Studio 300x Lens IMG-20240308-WA0002
Raspberry Pi HQ Camera Amazon 'Gringoo' Branded 130x Lens 1
Raspberry Pi HQ Camera Amazon 'Gringoo' Branded 130x Lens 2
Raspberry Pi HQ Camera Amazon 'Gringoo' Branded 130x Lens 3
Raspberry Pi HQ Camera Amazon 'Gringoo' Branded 130x Lens 4
lizzieinvancouver commented 8 months ago

@afong3 Super cool! They look pretty to me, but we should get perspectives from people who have looked at more rings ... @FrederikBaumgarten @DeirdreLoughnan and @wangxm-forest -- thoughts? I suspect they are high enough mag and just the sanding is perhaps the issue where seeing some things is tricky?

wangxm-forest commented 8 months ago

I might not be a best person to make a comment here. I scanned all my tree cores with a scanner at 1200 dpi resolution...These look great to me.

afong3 commented 8 months ago

The 300x lens is equivalent to about 38,000 dpi and the other lens is about 25,000 dpi.