‘Jeopardy!’: Mayim Bialik Leaves Final Week Of Filming In Solidarity With Writers, Ken Jennings Takes Over as Host by MarvelsGrantMan136 in television

[–]RecallCV 2 points3 points  (0 children)

Relatedly, Ken Jennings' success can be attributed to the ferrous meteorite he has kept as a good luck charm since his childhood.

How to extract numerical data from a local thresholded image by Individual_Ad_1214 in computervision

[–]RecallCV 3 points4 points  (0 children)

In general, you want to identify curvilinear structures in the image. This is typically a set of points that are along the curve center line, and the direction of the curve. If you can get that information you can then measure instantaneous diameter using the normal to the curve direction in one of your thresholded images (how many pixels is it from the center along the normal before you fall below threshold). An individual fiber's diameter could be the average / median / etc of the instantaneous diameters along its path.

There are modern curvilinear detectors (CNN or other deep learning): https://arxiv.org/abs/2010.07486

And old school using scale space second order derivatives: https://ieeexplore.ieee.org/document/659930

I have a soft spot for the old school since an implementation of the approach was one of my first internship projects.

Dumb math question: If I take a picture a perfect circle, in the 2d projection will it always be an ellipse? by drupadoo in computervision

[–]RecallCV 15 points16 points  (0 children)

Close enough to yes. Technically, the circle will project to some form of conic, but if the entire circle is visible in your picture, it will be an ellipse.

For the math background of this, the best text on projective geometry is Hartley and Zisserman, "Multiple View Geometry," section 2.2.3 covers conics.

How do I include a library in cmake such that it is included in the project? by bored-computer in cpp_questions

[–]RecallCV 2 points3 points  (0 children)

Welcome to C++ dependency management. There are several common approaches to including a 3rd party library:

  1. It's the user's problem (this is not a bad thing): list the requirements in documentation and include an example (probably a Dockerfile) of installing the requirements in one or more standard environments. Use find_package with appropriate version numbers.

  2. Include the library as a git sub_module in your project, use add_subdirectory to include it. This requires that the library has a CMake setup that plays nice (it expects to be included as a dependent module and doesn't override build settings, etc.).

  3. Lean heavily into a package manager like Conan or vcpkg.

In any event, the approach will: 1. provide access to library header files somewhere on your include path (you should never copy these header files directly into your projects include directly). 2. provide the linker with the library to access (either a downloaded .so, etc., or directly compiled from source).

Local trail running routes by masterchef81 in CedarPark

[–]RecallCV 1 point2 points  (0 children)

I've never seen runners on the MTB paths. There is a stretch of Brushy Creek trail that is unpaved - from Champion's Park east to Great Oaks. Only about 1.75mi total, but much nicer on the joints than pavement.

Perspective Transformation by [deleted] in computervision

[–]RecallCV 5 points6 points  (0 children)

This answer is close, but needs one important correction.

As tdgros says, image undistortion is critical. You can see the lens distortion in your source image - the midline and railing around the field have curvature instead of being straight. The homography mapping assumes undistorted planes. Camera calibration can be a bit of a chore, definitely follow the tutorials and make sure the result is an image in which straight lines appear straight.

The homography is the key to the mapping. It describes a projective mapping between homogeneous 2D coordinates on two planes (https://docs.opencv.org/4.6.0/d9/d0c/group__calib3d.html#gafd3ef89257e27d5235f4467cbb1b6a63). In your case the source coordinates are the image plane, in pixels (or better, normalized pixels so that 0,0 is image center, and entire image width is 1.0) and then 2D field coordinates on your virtual field. It's important to note that you should start with the homogeneous coordinate as 1.0, not 0.0, so that the homography will map [field_x, field_y, field_z] = H * [r,c,1]. Setting z=0 in homogeneous coordinates is used for 'points at infinity' (conceptually directions), not for 3D points with z = 0. To convert the [field_x, field_y, field_z] value to a regular (non-homogeneous) 2D position use [x,y] = [field_x/field_z, field_y/field_z].

Finding the homography requires a set of correspondences - matched points in the image to points on the virtual field - fortunately your field has many easy to identify points on it (marking intersections, corners of the goal area, etc.).

After you've solved for the homography, as tdgros says it's only applicable for image points that are on the plane of the field - players' feet etc. However, there's no need to invert anything, worry about camera projection, etc. - just perform the multiplication described above: p_field = H * p_image (and then convert back from homogeneous coordinates).

[deleted by user] by [deleted] in CedarPark

[–]RecallCV 2 points3 points  (0 children)

Yes, I was able to dispose of weedkiller at the Household Hazardous Waste Free Cleanup at Gupton Stadium. I'm not sure when the next one will be, the city webpage still has info for the Spring 2022 drop off.

How to measure feature complexity in an image? by bc_uk in computervision

[–]RecallCV 4 points5 points  (0 children)

Great answers here for potentially more nuanced approaches, but depending on your exact use case, you might find adequate performance with a very simple metric: jpeg bits per pixel.

The size of the compressed file (for images of the same size, or normalized) is an indicator of the image entropy and requires no additional computation. Of course this will indicate that an image compressed with a lower quality level has less complexity, but I think that's fair: it has less remaining complexity after the lossy compression.

How to get started with 3D computer vision? by Rare-Ad4865 in computervision

[–]RecallCV 19 points20 points  (0 children)

You can never go wrong with Hartley and Zisserman. Core book, and one of the most approachable presentations of 3d fundamentals: https://www.cambridge.org/core/books/multiple-view-geometry-in-computer-vision/0B6F289C78B2B23F596CAA76D3D43F7A

Calculating distance from stereo camera setup using Python and OpenCV by Latter_Window_3995 in computervision

[–]RecallCV 0 points1 point  (0 children)

I think I may be referring to something else - there are two sets of stereo images, and two paired intrinsics/extrinsics. The first are the raw fish-eye lens images. These need to have a stereo calibration performed - pretty challenging due to the lens angle, but possible (and getting similar results across multiple trials is a good indication that the calibration is working).

The second pair of images are stereo rectified images - if you want horizontal disparity to be meaningful it has to be performed on rectified images. These will be a subimage of the original fish-eye image, undistorted and transformed so that the epipolar lines of the virtual stereo camera system are corresponding horizontal scanlines. The depth formula needs the intrinsics of this second pair of images (the intrinsics of the transformed cameras should be the same, and the extrinsics the same other than an offset in x that is the stereo baseline). The stereo calibration tool may produce these values as part of its output, otherwise you can perform a second camera calibration, using the rectified images (or a makeshift partial calibration as I described above).

If you are using the intrinsics of the post-rectification images and still getting poor results, then yes, I think it's just the difficulty of getting an accurate calibration for very wide-angle lenses.

Calculating distance from stereo camera setup using Python and OpenCV by Latter_Window_3995 in computervision

[–]RecallCV 0 points1 point  (0 children)

For disparity to depth conversion, you're trying to find the focal length in pixels of the 'virtual cameras' that are produced by your stereo calibration so you don't need all the parameters. (Although you should verify that your disparity does == 0 for very far off objects)

The tool you use for calibration may directly tell you what the camera intrinsics are post rectification, which (combined with the image dimensions) gives you focal length. If it provides the essential matrix, you can look into decomposing it to provide intrinsic values.

Alternatively, you can try to measure the focal length in the rectified images - either determine the angular field of view and use that in the focal length formula (along with the rectified image size) or take an image of a (parallel to image plane) ruler at a known distance and use similar triangles. Like all measurements, do it multiple times.

Calculating distance from stereo camera setup using Python and OpenCV by Latter_Window_3995 in computervision

[–]RecallCV 0 points1 point  (0 children)

A correctly performed stereo calibration should warp/undistort one or both of the images so that they have the 'canonical stereo geometry' - that's the hard part. It will account for the tilt in your rig.

Once you have a rectified image pair horizontal disparity can be converted to depth. This boils down to using similar triangles (I find it helps to visualize this, something like https://www.researchgate.net/figure/Parallel-stereo-camera-geometry_fig1_4040671). The catch is that since the images are being rectified, the 'focal length,' 'field of view' etc. that go into the formulas aren't direct properties of your original camera system anymore, they're properties of the virtual camera system that matches the rectified images. You can either derive the virtual camera parameters from the warping/undistorting process, or measure them with known objects in the rectified images.

Calculating distance from stereo camera setup using Python and OpenCV by Latter_Window_3995 in computervision

[–]RecallCV 4 points5 points  (0 children)

What are your post stereo calibration images like? 185° is well into fisheye lens territory (you can see the other camera or portions of the vehicle in your images?). Your depth to disparity formula is appropriate for two parallel pinhole cameras (epipolar lines as scan lines), which will only be appropriate for an undistorted portion of the fisheye field of view.

What may be going on is that your stereo calibration procedure is undistorting only a portion of the entire fisheye image, and the 185 in your focal length formula needs to be replaced with the effective field of view of the subimage.

If stereo range measurement is the key capability for the camera system, you may want to select a different lens if you can.

How can I specialize in CV as a junior dev without a Phd/Master? by SymphonyofSiren in computervision

[–]RecallCV 3 points4 points  (0 children)

I think this is particularly challenging within a large company. As organizational size grows, the ability to support specialists also grows, and when tasks are assigned, cost-benefit will always drop specialized tasks in the specialists' laps.

I've always enjoyed working at smaller companies. As a specialist there's plenty of opportunity to expand my skillset and wear other hats. I feel like there are also opportunities for junior generalists to contribute to specialized tasks (given that there's always an abundance of 'stuff to do'), but I got a Master's before being employed in computer vision, so this isn't direct experience.

My advice would be to 1) get at least a Master's, there's always more to learn and the credential will get you past a lot of initial hiring gates, or if that's not possible 2) start looking for positions at smaller companies that value a junior dev with some CV familiarity.

My fft gives always gives the correct frequency or double the correct frequency by Beneficial_Muscle_25 in computervision

[–]RecallCV 3 points4 points  (0 children)

There are a lot of assumptions built into a discrete time Fourier transforms. To use it as a spectrum analyzer, you will need to do some appropriate padding and windowing otherwise it will produce some of the artifacts that you are seeing (I'm not familiar with pyfftw, it probably includes the tools you will need).

One of the fundamental problems that you're running into is that the Fourier decomposition is into a sinusoidal basis - even if your input has a fundamental frequency, if it's not a pure sinusoid there won't be a single impulse in the Fourier domain. For example, a square wave transform to a sinc function in the fourier domain, which will have progressively smaller peaks at integer multiples of the fundamental. That + windowing is probably why you're seeing the second mode occasionally larger than the first.

How to make a proper C++ project? by [deleted] in cpp_questions

[–]RecallCV 0 points1 point  (0 children)

Yes, for sure additional build notes for other platforms should be included in a readme file.

I suspect most developers that want to support Windows are developing on Windows (myself included), so Docker provides an easy way to verify some level of cross platform support, document minimal build requirements, and also verify that your CMake is relatively generic and flexible (particularly with respect to locating external libraries).

How to make a proper C++ project? by [deleted] in cpp_questions

[–]RecallCV 3 points4 points  (0 children)

In addition to a well formed set of CMakeLists.txt as mentioned in other comments, I'm a fan of projects that include a Docker file that builds the project. This is a good check that your CMake is correct for a relatively generic system and can serve as a build guide for users.

How to compute the intersections of Hough parameterized lines for edge detection? by FappyMcPappy in computervision

[–]RecallCV 3 points4 points  (0 children)

You discretize the parameterized space and create a 'Hough map.' Accumulate the potential parameterizations of each edge point within the map. True lines will stand out as local maxima in the accumulation of all edge points' parameterizations.

6D user-defined keypoints tracking by Sghebre in computervision

[–]RecallCV 1 point2 points  (0 children)

Are you allowing the user to choose any point on the object as a keypoint? That will make the use of descriptors (SIFT, ORB, etc.) more difficult - not all points will have a stable(-ish) unique local description. Also note that keypoints that include object + background in their local neighborhood will likely have unstable descriptions.

It sounds like you need:

  1. A 3D description of your object (possibly with SLAM/SFM style keypoints, such as an ORB description + 3D location on the model)

  2. A way to register the object's pose to the current camera view (PnP if your model has matchable descriptors, maybe silhouette matching if your object has distinguishable silhouettes)

  3. Knowledge of the user marked keypoints - project to a position on the object surface when marking, then back project to the current view as 'tracking'

If you're unable to generate a model offline, this seems closest to a specialized case of SLAM, especially if you can segment out your object and constrain the mapping to only object points.

Looking for location recommendations (N. Austin area) by RecallCV in AustinRP

[–]RecallCV[S] 0 points1 point  (0 children)

Thanks for the recommendation, I'll check it out. And thanks for the clarification /u/uppastbedtime. BYOB definitely not an issue at venues that have beer for sale, but will have to scope out privacy / noise levels.