cars.applications.grid_generation.grid_correction

Grids module: contains functions used for epipolar grid correction

Module Contents

Functions

correct_grid(grid, grid_correction)

Correct grid

estimate_right_grid_correction(matches, grid_right[, ...])

Estimates grid correction, and correct matches

create_matches_cars_ds(corrected_matches, initial_cars_ds)

Create CarsDataset representing matches, from numpy matches.

cars.applications.grid_generation.grid_correction.correct_grid(grid, grid_correction)

Correct grid

Parameters
  • grid (CarsDataset) – grid to correct

  • grid_correction – grid correction to apply

  • grid_correction – Tuple(np.ndarray, np.ndarray) (coefsx_2d, coefsy_2d) , each of size (2,2)

cars.applications.grid_generation.grid_correction.estimate_right_grid_correction(matches, grid_right, initial_cars_ds=None)

Estimates grid correction, and correct matches

Parameters
  • matches (np.ndarray) – matches

  • grid_right (CarsDataset) – grid to correct

Returns

grid_correction to apply, corrected_matches, info before, info after

Return type

Tuple(np.ndarray, np.ndarray) , np.ndarray, dict, dict grid_correction is : (coefsx_2d, coefsy_2d) , each of size (2,2)

cars.applications.grid_generation.grid_correction.create_matches_cars_ds(corrected_matches, initial_cars_ds)

Create CarsDataset representing matches, from numpy matches. Matches are split into tiles, stored in pandas DataFrames

Right CarsDataset is filled with Nones

Parameters
  • corrected_matches (numpy array) – matches

  • initial_cars_ds (CarsDataset) – cars dataset to use tiling from

:return matches_left, matches_right :rtype: CarsDataset, CarsDataset