CN117067859B - In-vehicle environment adjusting method based on vision - Google Patents

In-vehicle environment adjusting method based on vision Download PDF

Info

Publication number
CN117067859B
CN117067859B CN202311336839.8A CN202311336839A CN117067859B CN 117067859 B CN117067859 B CN 117067859B CN 202311336839 A CN202311336839 A CN 202311336839A CN 117067859 B CN117067859 B CN 117067859B
Authority
CN
China
Prior art keywords
smoke
value
environment
area
gray
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202311336839.8A
Other languages
Chinese (zh)
Other versions
CN117067859A (en
Inventor
廖恒
陈浪
甘茂煌
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shenzhen Blue Whale Zhilian Technology Co ltd
Original Assignee
Shenzhen Blue Whale Zhilian Technology Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shenzhen Blue Whale Zhilian Technology Co ltd filed Critical Shenzhen Blue Whale Zhilian Technology Co ltd
Priority to CN202311336839.8A priority Critical patent/CN117067859B/en
Publication of CN117067859A publication Critical patent/CN117067859A/en
Application granted granted Critical
Publication of CN117067859B publication Critical patent/CN117067859B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • BPERFORMING OPERATIONS; TRANSPORTING
    • B60VEHICLES IN GENERAL
    • B60HARRANGEMENTS OF HEATING, COOLING, VENTILATING OR OTHER AIR-TREATING DEVICES SPECIALLY ADAPTED FOR PASSENGER OR GOODS SPACES OF VEHICLES
    • B60H1/00Heating, cooling or ventilating [HVAC] devices
    • B60H1/00642Control systems or circuits; Control members or indication devices for heating, cooling or ventilating devices
    • B60H1/00735Control systems or circuits characterised by their input, i.e. by the detection, measurement or calculation of particular conditions, e.g. signal treatment, dynamic models
    • B60H1/008Control systems or circuits characterised by their input, i.e. by the detection, measurement or calculation of particular conditions, e.g. signal treatment, dynamic models the input being air quality
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/40Extraction of image or video features
    • G06V10/54Extraction of image or video features relating to texture
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/70Arrangements for image or video recognition or understanding using pattern recognition or machine learning
    • G06V10/762Arrangements for image or video recognition or understanding using pattern recognition or machine learning using clustering, e.g. of similar faces in social networks
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V20/00Scenes; Scene-specific elements
    • G06V20/50Context or environment of the image
    • G06V20/56Context or environment of the image exterior to a vehicle by using sensors mounted on the vehicle
    • G06V20/58Recognition of moving objects or obstacles, e.g. vehicles or pedestrians; Recognition of traffic objects, e.g. traffic signs, traffic lights or roads
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V20/00Scenes; Scene-specific elements
    • G06V20/50Context or environment of the image
    • G06V20/56Context or environment of the image exterior to a vehicle by using sensors mounted on the vehicle
    • G06V20/588Recognition of the road, e.g. of lane markings; Recognition of the vehicle driving pattern in relation to the road
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02TCLIMATE CHANGE MITIGATION TECHNOLOGIES RELATED TO TRANSPORTATION
    • Y02T10/00Road transport of goods or passengers
    • Y02T10/10Internal combustion engine [ICE] based vehicles
    • Y02T10/40Engine management systems

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Multimedia (AREA)
  • General Physics & Mathematics (AREA)
  • Artificial Intelligence (AREA)
  • Mechanical Engineering (AREA)
  • Health & Medical Sciences (AREA)
  • Thermal Sciences (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Computing Systems (AREA)
  • Databases & Information Systems (AREA)
  • Evolutionary Computation (AREA)
  • General Health & Medical Sciences (AREA)
  • Medical Informatics (AREA)
  • Software Systems (AREA)
  • Image Processing (AREA)

Abstract

The invention relates to the technical field of image processing, and provides an in-vehicle environment adjusting method based on vision, which comprises the following steps: acquiring a first environment image and acquiring a road area and a non-road area; acquiring a gray distribution scatter diagram and a gray centering value area corresponding to a road area, further determining a gray center distance of a pixel point in the road area, and further determining a smoke pixel point and a smoke serious area; acquiring a smoke environment significant value corresponding to the road area according to the gray center distance, the smoke pixel point and the smoke serious area; acquiring the influence degree of the smoke dust concentration corresponding to the road area; and acquiring a dark channel image, and acquiring a smoke influence value of the first environment image according to dark channel values, smoke environment significant values and smoke concentration influence values of pixel points in the non-road area and the road area, so as to realize self-adaptive adjustment of the environment in the vehicle, and solve the problem that the existing environment adjustment in the vehicle is based on manual independent control of an adult in the vehicle.

Description

In-vehicle environment adjusting method based on vision
Technical Field
The invention relates to the technical field of image processing, in particular to an in-vehicle environment adjusting method based on vision.
Background
In the running process of the automobile, if the automobile enters an industrial area, a region where sand and dust fly or other environments with severe air quality, the outer circulation of the automobile is required to be manually closed, the inner circulation is opened, and the automobile window is closed, so that dust can be prevented from entering the automobile, the air in the automobile is kept clean, the influence on the health of a human body is reduced, meanwhile, the noise of a road surface can be isolated, and the comfort of passengers in the automobile in the running process is improved. The interior environment of the automobile is formed by the seat, the window, the air conditioner and the like, which is one of important characteristics reflecting the comfort level of the automobile, and the adjustment of the equipment such as the seat, the window, the air conditioner and the like of the traditional automobile needs manual independent control of the personnel in the automobile, so that the attention of the driver is often required to be dispersed in the adjustment process, and a safe, humanized and intelligent interior environment adjusting technology is required to continuously improve the safety and the comfort level in the driving process, so that the automatic adjustment and control of the interior environment of the automobile are realized when the automobile is about to enter the smoke environment.
At present, an image around a vehicle can be obtained by using machine vision, when smoke dust appears in the surrounding environment of the vehicle, the actual environment around the vehicle under the influence of the smoke dust is identified by the machine vision, however, the influence degree of the smoke dust on the environment of the vehicle cannot be judged, and the self-use regulation and control of the environment in the vehicle cannot be realized, so that a method for realizing the automatic regulation of the environment in the vehicle according to the image of the surrounding environment of the vehicle is needed.
Disclosure of Invention
The invention provides a vision-based in-vehicle environment adjusting method, which aims to solve the problem that the existing in-vehicle environment adjusting is based on manual independent control of in-vehicle operators, and adopts the following technical scheme:
one embodiment of the present invention provides a vision-based in-vehicle environment adjustment method comprising the steps of:
acquiring a first environment image corresponding to the environment near the vehicle, and dividing a road area and a non-road area in the first environment image;
acquiring a gray distribution scatter diagram according to pixel points contained in a road area in a first environment image, dividing a gray centering value area from the gray distribution scatter diagram, acquiring gray center distances of pixel points corresponding to all the scattered points according to whether the scattered points in the gray distribution scatter diagram are in the gray centering value area, and determining a smoke pixel point and a smoke serious area according to the gray center distances of the pixel points;
acquiring a smoke environment significant value corresponding to the road area according to the gray center distance of the pixel points contained in the road area, the divided smoke pixel points and the smoke serious area;
acquiring detail richness corresponding to each pixel point in each smoke serious region and contrast corresponding to the smoke serious region, and acquiring smoke concentration influence degree corresponding to the road region according to the number of the smoke serious regions contained in the road region, the contrast corresponding to the smoke serious regions and the detail richness corresponding to the pixel points contained in the smoke serious regions;
acquiring a dark channel image according to the first environment image, acquiring a dark channel value corresponding to each pixel point, and acquiring a smoke influence value corresponding to the first environment image according to the numerical relation of the dark channel values of the pixels points in the non-road area and the road area in the dark channel image, the smoke environment significant value corresponding to the road area and the smoke concentration influence degree;
and realizing self-adaptive adjustment of the environment in the vehicle according to the smoke influence value corresponding to the first environment image.
Further, the method for acquiring the first environment image corresponding to the environment near the vehicle and dividing the road area and the non-road area in the first environment image comprises the following specific steps:
setting cameras at a plurality of preset positions of the automobile, correcting the azimuth shot by each camera, acquiring images once by using the cameras every first preset threshold time, and recording the acquired images as first environment images;
denoising the first environment image by using a preset denoising algorithm;
identifying a region corresponding to a road in a first environment image by using a target detection model, selecting pixel points of which the pixel value of a target channel in the region corresponding to the road is less than or equal to a second preset threshold value, and marking the region formed by the selected pixel points as a road region, wherein the second preset threshold value is used for limiting the monitoring range of the surrounding environment of the vehicle;
and (3) marking the area which is formed by all pixel points which are not in the road area and are provided with the pixel values of the channels and smaller than or equal to a second preset threshold value in the first environment image as a non-road area.
Further, the method for obtaining the gray distribution scatter diagram according to the pixel points contained in the road area in the first environment image includes the following specific steps:
converting the first ambient image into a first ambient grayscale image;
respectively taking each pixel point contained in a road area in a first environment gray level image as a central pixel point to establish a first preset size window, and recording the average value of gray level values of the pixel points contained in the window as a neighborhood average value of the central pixel point;
and taking the neighborhood mean value corresponding to the pixel point as an abscissa and the gray value corresponding to the pixel point as an ordinate, acquiring a gray distribution scatter diagram corresponding to the road region in the first environment image, and marking the scatter diagram corresponding to all the pixel points contained in the road region in the first environment image.
Further, the dividing the gray level centering value area from the gray level distribution scatter diagram comprises the following specific steps:
starting from the origin of the gray distribution scatter diagram, making rays with a preset included angle with the positive direction of the transverse axis to the first quadrant, taking two preset points on the rays, taking a line segment between the two preset points on the rays, respectively taking each pixel point contained in the line segment as a central pixel point to establish a second preset size window, and marking an area formed by all the pixel points contained in the second preset size window as a gray centering value area.
Further, the method for determining the smoke pixel point and the smoke serious area according to the gray center distance of the pixel points according to whether the scattered points in the gray distribution scattered points are in the gray centering value area or not comprises the following specific steps:
marking the gray center distance of the pixel point corresponding to the scattered point in the gray center value area in the gray distribution scattered point map as a first preset constant;
acquiring scattered points which are not in a gray level centering value area in a distribution scattered point, respectively taking each scattered point as a scattered point to be analyzed, acquiring Euclidean distance between the scattered point to be analyzed and each pixel point in the gray level centering value area, and taking the minimum value of the acquired Euclidean distance as the gray level center distance of the pixel point corresponding to the scattered point to be analyzed;
clustering the gray center distances of the pixel points corresponding to all the scattered points to obtain a plurality of clusters;
acquiring the average value of the gray center distances contained in each cluster, and marking the pixel points corresponding to all the gray center distances contained in the cluster with the smallest average value as smoke dust pixel points;
and carrying out connected domain analysis on the region formed by the smoke pixel points, and marking the acquired connected domain as a smoke serious region.
Further, the specific method for acquiring the smoke environment significant value corresponding to the road area comprises the following steps:
acquiring the ratio of the number of smoke pixel points in the road area to the number of pixel points contained in the road area, and marking the acquired ratio as a first ratio;
taking each smoke serious region in the road region as a smoke serious region to be analyzed, acquiring the average value of the gray center distances corresponding to all pixel points in the smoke serious region to be analyzed and the maximum value of the gray center distances corresponding to all pixel points, and recording the difference value of the maximum value of the gray center distances corresponding to all pixel points and the average value of the gray center distances corresponding to all pixel points as a first difference value of the smoke serious region to be analyzed;
recording the average value of the first difference value of each smoke serious area in the road area as a first average value;
and recording the product of the first average value and the first ratio as a smoke environment significant value corresponding to the road area.
Further, the specific method for obtaining the detail richness corresponding to each pixel point in each smoke serious area comprises the following steps:
and respectively taking each pixel point in each smoke serious area as a central pixel point to establish a first preset size window, taking information entropy corresponding to the pixel points contained in the window, and recording the information entropy as the detail richness of the central pixel point.
Further, the specific method for acquiring the influence of the concentration of the smoke comprises the following steps:
in the method, in the process of the invention,for road areasThe corresponding smoke concentration influence degree; />Is the +.>The number of pixels contained in the smoke serious region, wherein +.>;/>The number of smoke serious areas contained in the road area; />The total number of the pixel points contained in all the smoke serious areas contained in the road area; />Is->The contrast corresponding to the smoke serious area; />Is->The average value of detail richness corresponding to pixel points contained in the smoke serious areas; />Is a normalization function.
Further, the method for obtaining a dark channel image according to a first environment image, obtaining a dark channel value corresponding to each pixel point, and obtaining a smoke influence value corresponding to the first environment image according to a numerical relation of dark channel values of non-road areas and pixel points in road areas in the dark channel image, a smoke environment significant value corresponding to the road areas and a smoke concentration influence degree, includes the following specific steps:
obtaining a dark channel image by using a dark channel algorithm on the first environment image, and obtaining a dark channel value corresponding to each pixel point;
recording the average value of dark channel values corresponding to all pixel points contained in the road area as a second average value;
using an adaptive threshold segmentation algorithm to obtain an adaptive segmentation threshold for dark channel values corresponding to all pixel points contained in a non-road area, selecting pixel points with dark channel values larger than or equal to the adaptive segmentation threshold in the non-road area, and marking the average value of the dark channel values corresponding to the selected pixel points as a third average value;
when the third average value is greater than or equal to the second average value, the ratio of the third average value to the second average value is recorded as a second ratio, and the product of the second ratio and the smoke environment significant value and the smoke concentration influence degree corresponding to the road area is recorded as a smoke influence value corresponding to the first environment image;
and when the third average value is smaller than the second average value, taking the product of the smoke environment significant value corresponding to the road area and the smoke concentration influence degree as the smoke influence value corresponding to the first environment image.
Further, the specific method for acquiring the smoke influence value comprises the following steps:
in the method, in the process of the invention,the smoke influence value corresponding to the first environment image is obtained; />A smoke environment significant value corresponding to the road area;the influence degree of the smoke concentration corresponding to the road area is obtained; />Is the third mean value; />Is the second mean value; />Is a second predetermined constant.
The beneficial effects of the invention are as follows:
the method comprises the steps that a first environment image of the surrounding environment of a vehicle is obtained through a camera, and a road area and a non-road area in the first environment image are divided; firstly, analyzing a road area, acquiring the gray center distance of pixel points contained in the road area according to the position where the gray value distribution of the pixel points corresponding to the road in an image approaches to be relatively centered in the gray value range in the presence of smoke, dividing the gray center distance into smoke pixel points and a smoke serious area, and obtaining a smoke environment significant value corresponding to the road area according to the acquired indexes; secondly, according to the characteristics that the contrast of an image obtained when the environment around the vehicle is in smoke dust is reduced and the detailed information is blurred, the smoke dust concentration influence degree corresponding to a road area is obtained; then, according to the influence of the smoke concentration of the non-road area on the smoke concentration of the road area, the smoke environment significant value corresponding to the road area and the smoke concentration influence degree, acquiring a smoke influence value corresponding to the first environment image, and judging whether the vehicle is about to drive into the environment influenced by the smoke or not according to the influence of the smoke concentration of the non-road area on the smoke concentration of the road area and the influence of the smoke concentration of the non-road area; finally, the self-adaptive adjustment of the environment in the vehicle is realized according to the smoke influence value, so that the vehicle can be helped to keep the environment in the vehicle clean and quiet, and the comfort of passengers in the vehicle in the driving process is improved.
Drawings
In order to more clearly illustrate the embodiments of the invention or the technical solutions of the prior art, the drawings which are used in the description of the embodiments or the prior art will be briefly described, it being obvious that the drawings in the description below are only some embodiments of the invention, and that other drawings can be obtained according to these drawings without inventive faculty for a person skilled in the art.
Fig. 1 is a schematic flow chart of a vision-based in-vehicle environment adjustment method according to an embodiment of the present invention.
Detailed Description
The following description of the embodiments of the present invention will be made clearly and completely with reference to the accompanying drawings, in which it is apparent that the embodiments described are only some embodiments of the present invention, but not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the invention without making any inventive effort, are intended to be within the scope of the invention.
Referring to fig. 1, a flow chart of a vision-based in-vehicle environment adjustment method according to an embodiment of the invention is shown, the method includes the following steps:
step S001, acquiring a first environment image corresponding to the environment near the vehicle, and dividing a road area and a non-road area in the first environment image.
In order to obtain the surrounding environment of the automobile, an RGB-D camera is respectively arranged at the front, front left, front right, middle left, middle right, back left and back right of the automobile, and the shooting direction of each camera is corrected. Each intervalSecond, an image is acquired once using each camera provided, and each image acquired by the RGB-D camera is noted as a first environmental image. Wherein (1)>For the first threshold value set manually, the empirical value is 30, and the practitioner can set the first threshold value by himself as required.
And denoising each first environment image by using median filtering, so that the interference of noise on subsequent analysis is reduced, wherein denoising the first environment images by using median filtering is a known technology, and the details are not repeated, and an implementer can denoise the first environment images by using other denoising algorithms as required.
UsingThe YOLO identifies a region corresponding to the road in the first environment image, and selects a pixel value of a D channel in the region corresponding to the road to be less than or equal toThe region formed by these pixels is referred to as a road region, i.e., a region corresponding to the road on which the vehicle is traveling in the surrounding environment of the vehicle. The pixel value of the D channel which is not in the road area in the first environment image is less than or equal to +.>The area composed of all the pixels is referred to as a non-road area. Wherein (1)>The larger the second threshold value is, the wider the monitoring range of the surrounding environment of the vehicle is, the experience value is 50, and the operator can set the second threshold value according to the needs. The identification of the region corresponding to the road in the first environmental image by using YOLO is a known technique, and will not be described again.
Thus, a road area and a non-road area in the first environment image are acquired.
Step S002, a gray distribution scatter diagram is obtained according to pixel points contained in a road area in the first environment image, a gray centering value area is divided from the gray distribution scatter diagram, gray center distances of the pixel points corresponding to all the scattered points are obtained according to whether the scattered points in the gray distribution scatter diagram are in the gray centering value area, and a smoke pixel point and a smoke serious area are determined according to the gray center distances of the pixel points.
The first ambient image is converted into a first ambient grayscale image.
Taking all pixel points contained in a road area in a first environment gray level image, and respectively taking each pixel point as a central pixel point to establishAnd a window, wherein the average value of gray values of pixel points contained in the window is taken and is recorded as a neighborhood average value of the central pixel point. Wherein (1)>The constant is the experience value is 5, and the practitioner can set the constant according to the needs.
And taking the neighborhood mean value corresponding to the pixel point as an abscissa and the gray value corresponding to the pixel point as an ordinate, acquiring a gray distribution scatter diagram corresponding to the road region in the first environment image, and marking the scatter diagram corresponding to each pixel point contained in the road region in the first environment image.
The road on which the vehicle runs is usually asphalt road, the road is formed by paving asphalt concrete, the road keeps fine textures corresponding to the crushed stones, and the difference exists between the neighborhood average value corresponding to each pixel point and the gray value of the pixel point. When smoke dust appears in the area of the road corresponding to the vehicle running in the surrounding environment of the vehicle, the gray value distribution of the pixel points corresponding to the road in the image is enabled to approach to a relatively central position in the gray value range, so that the difference between the neighborhood average value and the gray value of the pixel points corresponding to the original road surface is reduced, and when the concentration of the smoke dust is larger, the characteristic is more obvious.
Dividing gray level centering value areas from the gray level distribution scatter diagram according to the characteristics.
Starting from the origin of the gray distribution scatter diagram, making rays with an included angle of 45 degrees with the positive direction of the transverse axis to the first quadrant, taking two fixed points A, B on the rays, taking a line segment between the two fixed points on the rays, and respectively establishing by taking each pixel point contained on the line segment as a central pixel pointAnd the window is used for marking the area formed by all the pixel points contained in the window corresponding to each pixel point contained in the line segment as a gray level centering value area. Wherein the fixed point A, B is a manually set point, and the coordinates of the two points in the gray distribution scatter diagram are +.>The implementer can set the device according to the needs; />The constant is the empirical value of 7, and the practitioner can set the empirical value according to the needs.
Acquiring scattered points corresponding to the gray distribution scattered points in all pixel points contained in a road area in a first environment image, acquiring the scattered points in a gray centering value area, and marking the gray center distances of the pixel points corresponding to the scattered points as 0; and acquiring scattered points which are not in the gray level centering value area in all pixel points contained in the road area in the first environment image, respectively taking each scattered point as a scattered point to be analyzed, analyzing, acquiring the minimum value of Euclidean distance between the scattered point to be analyzed and each pixel point in the gray level centering value area, and taking the minimum value of Euclidean distance as the gray level center distance of the pixel point corresponding to the scattered point to be analyzed.
When the gray center distance corresponding to a pixel point is smaller, the pixel point is more likely to correspond to an object in the environment where smoke dust appears; when the gray center distance corresponding to the pixel points contained in the road area is smaller, the road area is more likely to be in the smoke environment, and smoke is more concentrated.
And clustering the gray center distances of all the pixel points by using an OPTICS clustering algorithm, wherein the empirical value of the parameter MinPts is 5, and a plurality of clustering clusters are obtained. And respectively taking the average value of the gray center distances contained in each cluster, selecting all the gray center distances contained in the cluster with the smallest average value, and marking the pixel points corresponding to the selected gray center distances as smoke dust pixel points, wherein the smoke dust pixel points are the pixel points with stronger smoke dust characteristics in the road area. And carrying out connected domain analysis on the region formed by the smoke pixel points, and marking the acquired connected domain as a smoke serious region.
And step S003, obtaining a smoke environment significant value corresponding to the road area according to the gray center distance of the pixel points contained in the road area, the divided smoke pixel points and the smoke serious area.
The method for acquiring the smoke environment significant value corresponding to the road area comprises the following steps:
in the method, in the process of the invention,a smoke environment significant value corresponding to the road area; />The ratio of the number of the smoke pixel points in the road area to the number of the pixel points contained in the road area is set; />Is->The average value of gray center distances corresponding to all pixel points contained in the smoke serious region, wherein +.>;/>The number of the smoke serious areas contained in the road area; />Is->And the maximum value of the gray center distance corresponding to the pixel points in the smoke serious region.
When the area of the smoke serious area divided in the road area is larger, the gray center distance corresponding to the pixel point in the smoke serious area is smaller, the smoke environment significant value corresponding to the road area is larger, namely the possibility that the road area is in the smoke environment is larger, and the smoke is thicker.
So far, the smoke environment significant value corresponding to the road area is obtained.
Step S004, the detail richness corresponding to each pixel point in each smoke serious area and the contrast corresponding to the smoke serious area are obtained, and the smoke concentration influence degree corresponding to the road area is obtained according to the number of the smoke serious areas contained in the road area, the contrast corresponding to the smoke serious areas and the detail richness corresponding to the pixel points contained in the smoke serious areas.
When the environment around the vehicle is in smoke, the contrast of the acquired image is reduced, and the detail information is blurred, so that the detail information in the road area is analyzed.
Acquiring the corresponding pixel point in each smoke serious areaAnd the window is used for taking the information entropy corresponding to the pixel points contained in the window, and taking the entropy value as the detail richness of the central pixel point. When the detail richness corresponding to the pixel points contained in the smoke serious region is larger, the detail information of the smoke serious region is more abundant, namely the probability that the smoke serious region is in a smoke environment is smaller.
And acquiring a gray level co-occurrence matrix corresponding to each smoke severe area, and acquiring the contrast corresponding to the smoke severe area according to the gray level co-occurrence matrix. The contrast reflects the sharpness of the image and the depth of the texture grooves, and when the contrast is larger, the sharpness of the image is larger and the texture is deeper.
And acquiring the influence degree of the smoke concentration corresponding to the road area according to the analysis of each smoke serious area.
In the method, in the process of the invention,the influence degree of the smoke concentration corresponding to the road area is obtained; />Is the +.>The number of pixels contained in the smoke serious region, wherein +.>;/>The number of smoke serious areas contained in the road area; />The total number of the pixel points contained in all the smoke serious areas contained in the road area; />Is->The contrast corresponding to the smoke serious area; />Is->The average value of detail richness corresponding to pixel points contained in the smoke serious areas; />As a normalization function, it acts as a normalization value in brackets.
When the detail richness and contrast corresponding to the smoke serious region contained in the road region are smaller, the probability that the smoke serious region is in the environment influenced by smoke is smaller; when the number of the pixel points contained in each smoke serious region is more than the total number of the pixel points contained in all the smoke serious regions contained in the road region, the influence of the smoke conditions corresponding to the smoke serious regions on the smoke concentration influence degree corresponding to the road region is larger.
The significance and the degree of influence of the smoke on the road area are evaluated by the significance and the degree of influence of the smoke on the road area, and when the significance and the degree of influence of the smoke on the smoke corresponding to the road area are larger, the possibility that the road area is in the environment of influence of the smoke is larger.
So far, the influence degree of the smoke concentration corresponding to the road area is obtained.
Step S005, obtaining a dark channel image according to the first environment image, obtaining a dark channel value corresponding to each pixel point, and obtaining a smoke influence value corresponding to the first environment image according to the numerical relation of the dark channel values of the pixels points in the non-road area and the road area in the dark channel image, the smoke environment significant value corresponding to the road area and the smoke concentration influence degree.
Because the environment changes, when the influence of the smoke dust in the non-road area is larger than or equal to that of the road area, the influence of the smoke dust is more influenced when the automobile runs to the positions, so that the influence degree of the smoke dust in the non-road area is continuously analyzed, and the influence of the smoke dust in the surrounding environment of the automobile is more accurately determined.
A dark channel image is acquired from the first ambient image using a dark channel algorithm. The dark channel image is a gray image, and when the dark channel value corresponding to the pixel point is larger, the position of the pixel point is more influenced by smoke dust. And taking the average value of the dark channel values corresponding to all the pixel points contained in the road area in the dark channel image. And taking dark channel values corresponding to all pixel points contained in a non-road area in the dark channel image, dividing the selected dark channel values by using a maximum inter-class variance method, obtaining a divided self-adaptive threshold value, selecting pixel points with dark channel values larger than or equal to the self-adaptive dividing threshold value in the non-road area, and taking the average value of the dark channel values corresponding to the pixel points.
When the average value of the dark channel values corresponding to the non-road area is larger than the average value of the dark channel values corresponding to the road area, the influence of smoke dust in the non-road area is larger than or equal to that of the road area, and when the automobile runs to the positions, the influence of the smoke dust is often larger, so that the influence of the smoke dust of the surrounding environment of the automobile is required to be properly improved, and the smoke dust influence value corresponding to the first environment image is acquired based on the influence.
In the method, in the process of the invention,the smoke influence value corresponding to the first environment image is obtained; />A smoke environment significant value corresponding to the road area;the influence degree of the smoke concentration corresponding to the road area is obtained; />The average value of dark channel values corresponding to pixel points with dark channel values larger than or equal to the self-adaptive dividing threshold value in the non-road area is obtained; />The average value of dark channel values corresponding to all pixel points contained in the road area is obtained; />The constant is the empirical value of 1, and the practitioner can set the empirical value according to the needs.
When the smoke environment significant value and the smoke concentration influence degree corresponding to the road area are larger and the smoke influence degree of the non-road area relative to the road area is larger, the smoke influence value corresponding to the first environment image is larger, and the possibility that the road area is in the smoke influenced environment is larger.
So far, the smoke influence value corresponding to the first environment image is obtained.
And step S006, realizing the self-adaptive adjustment of the environment in the vehicle according to the smoke influence value corresponding to the first environment image.
And taking a normalized value of the smoke influence value corresponding to the first environment image, and when the normalized value of the smoke influence value is greater than or equal to a third threshold value, considering that the environment of the position near the vehicle corresponding to the first environment image is influenced by smoke.
A plurality of cameras arranged around the vehicle CAN acquire a plurality of first environment images at the same moment, when the situation that the first environment images are larger than or equal to a fourth threshold value is judged that the environment of the corresponding position near the vehicle is influenced by smoke dust, the vehicle is considered to be about to drive into the environment influenced by the smoke dust, equipment such as a seat, a window and an air conditioner of the vehicle is controlled through a CAN, the outer circulation of the vehicle is automatically closed, the inner circulation is opened, the window is closed, dust is prevented from entering the vehicle, the air in the vehicle is kept clean, the influence on the health of a human body is reduced, the noise of a road surface is isolated, and the comfort of passengers in the vehicle in the driving process is improved.
The third threshold and the fourth threshold have experience values of 0.5 and 3 respectively, and can be set by an implementer according to the needs.
The foregoing description of the preferred embodiments of the invention is not intended to be limiting, but rather is intended to cover all modifications, equivalents, alternatives, and improvements that fall within the spirit and scope of the invention.

Claims (8)

1. A vision-based in-vehicle environment adjustment method, comprising the steps of:
acquiring a first environment image corresponding to the environment near the vehicle, and dividing a road area and a non-road area in the first environment image;
acquiring a gray distribution scatter diagram according to pixel points contained in a road area in a first environment image, dividing a gray centering value area from the gray distribution scatter diagram, acquiring gray center distances of pixel points corresponding to all the scattered points according to whether the scattered points in the gray distribution scatter diagram are in the gray centering value area, and determining a smoke pixel point and a smoke serious area according to the gray center distances of the pixel points;
acquiring a smoke environment significant value corresponding to the road area according to the gray center distance of the pixel points contained in the road area, the divided smoke pixel points and the smoke serious area;
acquiring detail richness corresponding to each pixel point in each smoke serious region and contrast corresponding to the smoke serious region, and acquiring smoke concentration influence degree corresponding to the road region according to the number of the smoke serious regions contained in the road region, the contrast corresponding to the smoke serious regions and the detail richness corresponding to the pixel points contained in the smoke serious regions;
acquiring a dark channel image according to the first environment image, acquiring a dark channel value corresponding to each pixel point, and acquiring a smoke influence value corresponding to the first environment image according to the numerical relation of the dark channel values of the pixels points in the non-road area and the road area in the dark channel image, the smoke environment significant value corresponding to the road area and the smoke concentration influence degree;
according to the smoke influence value corresponding to the first environment image, the self-adaptive adjustment of the environment in the vehicle is realized;
the method for determining the smoke pixel point and the smoke serious area according to the gray center distances of the pixel points comprises the following specific steps:
marking the gray center distance of the pixel point corresponding to the scattered point in the gray center value area in the gray distribution scattered point map as a first preset constant;
acquiring scattered points which are not in a gray level centering value area in a distribution scattered point, respectively taking each scattered point as a scattered point to be analyzed, acquiring Euclidean distance between the scattered point to be analyzed and each pixel point in the gray level centering value area, and taking the minimum value of the acquired Euclidean distance as the gray level center distance of the pixel point corresponding to the scattered point to be analyzed;
clustering the gray center distances of the pixel points corresponding to all the scattered points to obtain a plurality of clusters;
acquiring the average value of the gray center distances contained in each cluster, and marking the pixel points corresponding to all the gray center distances contained in the cluster with the smallest average value as smoke dust pixel points;
carrying out connected domain analysis on a region formed by smoke pixel points, and marking the acquired connected domain as a smoke serious region;
the specific method for acquiring the smoke environment significant value corresponding to the road area comprises the following steps:
acquiring the ratio of the number of smoke pixel points in the road area to the number of pixel points contained in the road area, and marking the acquired ratio as a first ratio;
taking each smoke serious region in the road region as a smoke serious region to be analyzed, acquiring the average value of the gray center distances corresponding to all pixel points in the smoke serious region to be analyzed and the maximum value of the gray center distances corresponding to all pixel points, and recording the difference value of the maximum value of the gray center distances corresponding to all pixel points and the average value of the gray center distances corresponding to all pixel points as a first difference value of the smoke serious region to be analyzed;
recording the average value of the first difference value of each smoke serious area in the road area as a first average value;
and recording the product of the first average value and the first ratio as a smoke environment significant value corresponding to the road area.
2. The vision-based in-vehicle environment adjustment method according to claim 1, wherein the steps of acquiring a first environment image corresponding to an environment near a vehicle and dividing a road area and a non-road area in the first environment image include the following specific steps:
setting cameras at a plurality of preset positions of the automobile, correcting the azimuth shot by each camera, acquiring images once by using the cameras every first preset threshold time, and recording the acquired images as first environment images;
denoising the first environment image by using a preset denoising algorithm;
identifying a region corresponding to a road in a first environment image by using a target detection model, selecting pixel points of which the pixel value of a target channel in the region corresponding to the road is less than or equal to a second preset threshold value, and marking the region formed by the selected pixel points as a road region, wherein the second preset threshold value is used for limiting the monitoring range of the surrounding environment of the vehicle;
and (3) marking the area which is formed by all pixel points which are not in the road area and are provided with the pixel values of the channels and smaller than or equal to a second preset threshold value in the first environment image as a non-road area.
3. The vision-based in-vehicle environment adjustment method according to claim 1, wherein the acquiring the gray-scale distribution scatter diagram according to the pixel points included in the road area in the first environment image comprises the following specific steps:
converting the first ambient image into a first ambient grayscale image;
respectively taking each pixel point contained in a road area in a first environment gray level image as a central pixel point to establish a first preset size window, and recording the average value of gray level values of the pixel points contained in the window as a neighborhood average value of the central pixel point;
and taking the neighborhood mean value corresponding to the pixel point as an abscissa and the gray value corresponding to the pixel point as an ordinate, acquiring a gray distribution scatter diagram corresponding to the road region in the first environment image, and marking the scatter diagram corresponding to all the pixel points contained in the road region in the first environment image.
4. The vision-based in-vehicle environment adjustment method according to claim 1, wherein the dividing the gray-scale centering value area from the gray-scale distribution scatter diagram comprises the following specific steps:
starting from the origin of the gray distribution scatter diagram, making rays with a preset included angle with the positive direction of the transverse axis to the first quadrant, taking two preset points on the rays, taking a line segment between the two preset points on the rays, respectively taking each pixel point contained in the line segment as a central pixel point to establish a second preset size window, and marking an area formed by all the pixel points contained in the second preset size window as a gray centering value area.
5. The vision-based in-vehicle environment adjustment method according to claim 1, wherein the obtaining the detail richness corresponding to each pixel point in each smoke serious area comprises the following specific steps:
and respectively taking each pixel point in each smoke serious area as a central pixel point to establish a first preset size window, taking information entropy corresponding to the pixel points contained in the window, and recording the information entropy as the detail richness of the central pixel point.
6. The vision-based in-vehicle environment adjustment method according to claim 1, wherein the specific method for obtaining the smoke concentration influence degree is as follows:
in the method, in the process of the invention,the influence degree of the smoke concentration corresponding to the road area is obtained; />Is the +.>The number of pixels contained in the smoke serious region, wherein +.>;/>The number of the smoke serious areas contained in the road area; />The total number of the pixel points contained in all the smoke serious areas contained in the road area; />Is->The contrast corresponding to the smoke serious area; />Is->The smoke serious region comprises fine pixels corresponding toMean value of section richness; />Is a normalization function.
7. The vision-based in-vehicle environment adjustment method according to claim 1, wherein the obtaining a dark channel image according to a first environment image, obtaining a dark channel value corresponding to each pixel point, and obtaining a smoke impact value corresponding to the first environment image according to a numerical relationship between dark channel values of non-road areas and pixel points in road areas in the dark channel image, a smoke environment significant value corresponding to the road areas, and a smoke concentration impact value, comprises the following specific steps:
obtaining a dark channel image by using a dark channel algorithm on the first environment image, and obtaining a dark channel value corresponding to each pixel point;
recording the average value of dark channel values corresponding to all pixel points contained in the road area as a second average value;
using an adaptive threshold segmentation algorithm to obtain an adaptive segmentation threshold for dark channel values corresponding to all pixel points contained in a non-road area, selecting pixel points with dark channel values larger than or equal to the adaptive segmentation threshold in the non-road area, and marking the average value of the dark channel values corresponding to the selected pixel points as a third average value;
when the third average value is greater than or equal to the second average value, the ratio of the third average value to the second average value is recorded as a second ratio, and the product of the second ratio and the smoke environment significant value and the smoke concentration influence degree corresponding to the road area is recorded as a smoke influence value corresponding to the first environment image;
and when the third average value is smaller than the second average value, taking the product of the smoke environment significant value corresponding to the road area and the smoke concentration influence degree as the smoke influence value corresponding to the first environment image.
8. The vision-based in-vehicle environment adjustment method according to claim 1, wherein the specific method for obtaining the smoke influence value is as follows:
in the method, in the process of the invention,the smoke influence value corresponding to the first environment image is obtained; />A smoke environment significant value corresponding to the road area; />The influence degree of the smoke concentration corresponding to the road area is obtained; />Is the third mean value; />Is the second mean value; />Is a second predetermined constant.
CN202311336839.8A 2023-10-17 2023-10-17 In-vehicle environment adjusting method based on vision Active CN117067859B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202311336839.8A CN117067859B (en) 2023-10-17 2023-10-17 In-vehicle environment adjusting method based on vision

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202311336839.8A CN117067859B (en) 2023-10-17 2023-10-17 In-vehicle environment adjusting method based on vision

Publications (2)

Publication Number Publication Date
CN117067859A CN117067859A (en) 2023-11-17
CN117067859B true CN117067859B (en) 2024-01-16

Family

ID=88717641

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202311336839.8A Active CN117067859B (en) 2023-10-17 2023-10-17 In-vehicle environment adjusting method based on vision

Country Status (1)

Country Link
CN (1) CN117067859B (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114387273A (en) * 2022-03-24 2022-04-22 莱芜职业技术学院 Environmental dust concentration detection method and system based on computer image recognition
CN114734771A (en) * 2022-03-10 2022-07-12 东风汽车集团股份有限公司 In-vehicle air quality guarantee method and system based on visual identification
CN116357198A (en) * 2023-04-17 2023-06-30 长城汽车股份有限公司 Vehicle window control method and system and vehicle
CN116823824A (en) * 2023-08-29 2023-09-29 山东济宁运河煤矿有限责任公司 Underground belt conveyor dust fall detecting system based on machine vision

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114734771A (en) * 2022-03-10 2022-07-12 东风汽车集团股份有限公司 In-vehicle air quality guarantee method and system based on visual identification
CN114387273A (en) * 2022-03-24 2022-04-22 莱芜职业技术学院 Environmental dust concentration detection method and system based on computer image recognition
CN116357198A (en) * 2023-04-17 2023-06-30 长城汽车股份有限公司 Vehicle window control method and system and vehicle
CN116823824A (en) * 2023-08-29 2023-09-29 山东济宁运河煤矿有限责任公司 Underground belt conveyor dust fall detecting system based on machine vision

Also Published As

Publication number Publication date
CN117067859A (en) 2023-11-17

Similar Documents

Publication Publication Date Title
CN109740595B (en) Oblique vehicle detection and tracking system and method based on machine vision
US8102417B2 (en) Eye closure recognition system and method
US7940962B2 (en) System and method of awareness detection
CN108038416B (en) Lane line detection method and system
CN108389175B (en) Image defogging method integrating variation function and color attenuation prior
US20060204042A1 (en) System and method for determining eye closure state
CN109977930B (en) Fatigue driving detection method and device
CN111553214B (en) Method and system for detecting smoking behavior of driver
TW201716266A (en) Image inpainting system area and method using the same
CN109242032B (en) Target detection method based on deep learning
CN112149476B (en) Target detection method, device, equipment and storage medium
CN110060221B (en) Bridge vehicle detection method based on unmanned aerial vehicle aerial image
CN112001920B (en) Fundus image recognition method, device and equipment
CN114708567B (en) Road surface hollow detection and avoidance method and system based on binocular camera
CN116310845A (en) Intelligent monitoring system for sewage treatment
CN117067859B (en) In-vehicle environment adjusting method based on vision
CN114581374A (en) Electric vehicle driving assisting system based on artificial intelligence technology
CN106815558A (en) Car based on image recognition enters tunnel headlight and shifts to an earlier date open method automatically
CN108229244A (en) A kind of detection method of intelligent vehicle forward vehicle
CN112598002B (en) License plate recognition method under influence of fog and noise
CN116416152A (en) Image data-based processing method and device
CN115684156A (en) Coagulation unit water production state early warning method based on floc identification
CN109409347A (en) A method of based on facial features localization fatigue driving
CN111950409B (en) Intelligent identification method and system for road marking line
CN110647843B (en) Face image processing method

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant