lesson_functions module¶
This module contains procedures provide in the “Udacity Self-Driving Car Engineer Nanodegree” lecture notes. Some modifications were made. https://www.udacity.com/course/self-driving-car-engineer-nanodegree–nd013
-
lesson_functions.
bin_spatial
(img, size=(32, 32))[source]¶ Define a function to compute binned color features
-
lesson_functions.
color_hist
(img, nbins=32, bins_range=(0, 256))[source]¶ Define a function to compute color histogram features
-
lesson_functions.
detect_cars_in_image
(image, svc, X_scaler, color_space='RGB', orient=9, pix_per_cell=8, cell_per_block=2, channel=0, spatial_size=(16, 16), hist_bins=16, spatial_feat=True, hist_feat=True, hog_feat=True, y_start_stop=[400, 650], xy_windows=[(64, 64)])[source]¶
-
lesson_functions.
draw_boxes
(img, bboxes, color=(0, 0, 255), thick=6)[source]¶ Define a function to draw bounding boxes
-
lesson_functions.
extract_features
(imgs, color_space='RGB', spatial_size=(32, 32), hist_bins=32, orient=9, pix_per_cell=8, cell_per_block=2, channel=0, spatial_feat=True, hist_feat=True, hog_feat=True)[source]¶ Define a function to extract features from a list of images
-
lesson_functions.
find_cars
(img, svc, X_scaler, ystart=400, ystop=650, scale=1, spatial_size=(32, 32), hist_bins=32, orient=9, pix_per_cell=8, cell_per_block=2)[source]¶
-
lesson_functions.
get_hog_features
(img, orient, pix_per_cell, cell_per_block, vis=False, feature_vec=True)[source]¶ Define a function to return HOG features and visualization
-
lesson_functions.
heat_map
(image, box_list, threshold=1)[source]¶ Create a heat map based box list and threshold
-
lesson_functions.
search_windows
(img, windows, clf, scaler, color_space='RGB', spatial_size=(32, 32), hist_bins=32, hist_range=(0, 256), orient=9, pix_per_cell=8, cell_per_block=2, channel=0, spatial_feat=True, hist_feat=True, hog_feat=True)[source]¶ Define a function you will pass an image and the list of windows to be searched (output of slide_windows())
-
lesson_functions.
single_img_features
(img, color_space='RGB', spatial_size=(32, 32), hist_bins=32, orient=9, pix_per_cell=8, cell_per_block=2, channel=0, spatial_feat=True, hist_feat=True, hog_feat=True)[source]¶ Define a function to extract features from a single image window This function is very similar to extract_features() just for a single image rather than list of images