CropRowDetector¶
Qualified name: crop_row_detector.crop_row_detector.CropRowDetector
- class CropRowDetector[source]¶
Bases:
objectMethods
add_boundary_and_number_to_tileappend_to_csv_of_row_informationappend_to_csv_of_row_information_globalappend_to_csv_vegetation_rowapply_hough_linesapply_top_hatblur_imagecalculate_x_and_y_sample_cords_along_crop_rowConvert compass angles (0 north 90 east 180 south and 270 west) to radians in hough space.
convert_segmented_image_to_bwcreate_csv_of_row_informationcreate_csv_of_row_information_globalcreate_data_structure_containing_crop_rowdetect_crop_rowsdetect_crop_rows_as_processdetect_crop_rows_on_tiles_with_process_poolsdetect_crop_rows_on_tiles_with_threadsdetermine_dominant_directiondetermine_line_ends_of_crop_rowsdetermine_offsets_of_crop_rowsdraw_crop_rowdraw_detected_crop_rows_on_imageensure_parent_directory_existfill_in_gaps_in_detected_crop_rowsfind_vegetation_in_crop_rowget_debug_output_filepathget_line_ends_within_imagemeasure_vegetation_coverage_in_crop_rownormalize_arrayplot_direction_energiesplot_direction_response_and_maximumplot_points_without_vegetation_on_crop_rowplot_row_offsetplot_row_offset_with_peaksprepare_csv_filessave_statisticsvegetation_row_to_csvwrite_debug_image_to_filewrite_debug_plot_to_file- compass_degree_angle_to_hough_rad(degree_angle)[source]¶
Convert compass angles (0 north 90 east 180 south and 270 west) to radians in hough space. Since the hough angle is measured in image coordinates (origin in top left corner and y going down) and the angle is to the normal of the line measured on the unit circle, correcting for this ends opp canceling each other as we can always add 180 degrees since it is a line.