CN113222186A - Intelligent garbage classification system - Google Patents
Intelligent garbage classification system Download PDFInfo
- Publication number
- CN113222186A CN113222186A CN202110316322.7A CN202110316322A CN113222186A CN 113222186 A CN113222186 A CN 113222186A CN 202110316322 A CN202110316322 A CN 202110316322A CN 113222186 A CN113222186 A CN 113222186A
- Authority
- CN
- China
- Prior art keywords
- garbage
- classification
- module
- intelligent
- cloud server
- 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.)
- Granted
Links
- 239000010813 municipal solid waste Substances 0.000 title claims abstract description 343
- 238000003066 decision tree Methods 0.000 claims abstract description 21
- 238000012545 processing Methods 0.000 claims abstract description 18
- 238000012549 training Methods 0.000 claims description 55
- 230000006835 compression Effects 0.000 claims description 51
- 238000007906 compression Methods 0.000 claims description 51
- 238000000034 method Methods 0.000 claims description 28
- 238000004891 communication Methods 0.000 claims description 24
- 238000010606 normalization Methods 0.000 claims description 16
- 230000008569 process Effects 0.000 claims description 16
- 238000013527 convolutional neural network Methods 0.000 claims description 12
- 230000006870 function Effects 0.000 claims description 12
- 239000011159 matrix material Substances 0.000 claims description 12
- 238000011176 pooling Methods 0.000 claims description 12
- 230000004913 activation Effects 0.000 claims description 11
- 230000004044 response Effects 0.000 claims description 10
- 238000005516 engineering process Methods 0.000 claims description 9
- 238000006243 chemical reaction Methods 0.000 claims description 7
- 230000005284 excitation Effects 0.000 claims description 7
- 240000007651 Rubus glaucus Species 0.000 claims description 6
- 235000011034 Rubus glaucus Nutrition 0.000 claims description 6
- 235000009122 Rubus idaeus Nutrition 0.000 claims description 6
- 238000011478 gradient descent method Methods 0.000 claims description 6
- 230000002087 whitening effect Effects 0.000 claims description 6
- 238000004364 calculation method Methods 0.000 claims description 4
- 238000004806 packaging method and process Methods 0.000 claims description 4
- 238000012935 Averaging Methods 0.000 claims description 3
- 230000008859 change Effects 0.000 claims description 3
- 238000000354 decomposition reaction Methods 0.000 claims description 3
- 230000009191 jumping Effects 0.000 claims description 3
- 230000000694 effects Effects 0.000 abstract description 6
- 238000004519 manufacturing process Methods 0.000 abstract description 4
- 210000002569 neuron Anatomy 0.000 description 5
- 238000010586 diagram Methods 0.000 description 4
- 239000002699 waste material Substances 0.000 description 4
- 229910000838 Al alloy Inorganic materials 0.000 description 3
- 230000009286 beneficial effect Effects 0.000 description 3
- 230000008901 benefit Effects 0.000 description 3
- 238000004064 recycling Methods 0.000 description 3
- 239000003086 colorant Substances 0.000 description 2
- 238000013461 design Methods 0.000 description 2
- 238000011161 development Methods 0.000 description 2
- 230000007613 environmental effect Effects 0.000 description 2
- 238000013507 mapping Methods 0.000 description 2
- 230000009467 reduction Effects 0.000 description 2
- 235000017166 Bambusa arundinacea Nutrition 0.000 description 1
- 235000017491 Bambusa tulda Nutrition 0.000 description 1
- OKTJSMMVPCPJKN-UHFFFAOYSA-N Carbon Chemical compound [C] OKTJSMMVPCPJKN-UHFFFAOYSA-N 0.000 description 1
- 244000082204 Phyllostachys viridis Species 0.000 description 1
- 235000015334 Phyllostachys viridis Nutrition 0.000 description 1
- 230000003321 amplification Effects 0.000 description 1
- 239000011425 bamboo Substances 0.000 description 1
- 229910052799 carbon Inorganic materials 0.000 description 1
- 230000002860 competitive effect Effects 0.000 description 1
- 238000004134 energy conservation Methods 0.000 description 1
- 238000003912 environmental pollution Methods 0.000 description 1
- 239000002920 hazardous waste Substances 0.000 description 1
- 230000006698 induction Effects 0.000 description 1
- 230000005764 inhibitory process Effects 0.000 description 1
- 238000009434 installation Methods 0.000 description 1
- 230000023886 lateral inhibition Effects 0.000 description 1
- 230000007246 mechanism Effects 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 238000003199 nucleic acid amplification method Methods 0.000 description 1
- 239000010819 recyclable waste Substances 0.000 description 1
- 230000007306 turnover Effects 0.000 description 1
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06Q—INFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
- G06Q10/00—Administration; Management
- G06Q10/30—Administration of product recycling or disposal
-
- B—PERFORMING OPERATIONS; TRANSPORTING
- B65—CONVEYING; PACKING; STORING; HANDLING THIN OR FILAMENTARY MATERIAL
- B65F—GATHERING OR REMOVAL OF DOMESTIC OR LIKE REFUSE
- B65F1/00—Refuse receptacles; Accessories therefor
- B65F1/0033—Refuse receptacles; Accessories therefor specially adapted for segregated refuse collecting, e.g. receptacles with several compartments; Combination of receptacles
- B65F1/0053—Combination of several receptacles
- B65F1/0066—Rigid receptacles fixed on racks or posts
-
- B—PERFORMING OPERATIONS; TRANSPORTING
- B65—CONVEYING; PACKING; STORING; HANDLING THIN OR FILAMENTARY MATERIAL
- B65F—GATHERING OR REMOVAL OF DOMESTIC OR LIKE REFUSE
- B65F1/00—Refuse receptacles; Accessories therefor
- B65F1/14—Other constructional features; Accessories
- B65F1/1405—Compressing means incorporated in, or specially adapted for, refuse receptacles
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F17/00—Digital computing or data processing equipment or methods, specially adapted for specific functions
- G06F17/10—Complex mathematical operations
- G06F17/16—Matrix or vector computation, e.g. matrix-matrix or matrix-vector multiplication, matrix factorization
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F18/00—Pattern recognition
- G06F18/20—Analysing
- G06F18/21—Design or setup of recognition systems or techniques; Extraction of features in feature space; Blind source separation
- G06F18/214—Generating training patterns; Bootstrap methods, e.g. bagging or boosting
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06N—COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
- G06N3/00—Computing arrangements based on biological models
- G06N3/02—Neural networks
- G06N3/04—Architecture, e.g. interconnection topology
- G06N3/045—Combinations of networks
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06N—COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
- G06N3/00—Computing arrangements based on biological models
- G06N3/02—Neural networks
- G06N3/08—Learning methods
- G06N3/084—Backpropagation, e.g. using gradient descent
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/01—Protocols
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/01—Protocols
- H04L67/02—Protocols based on web technology, e.g. hypertext transfer protocol [HTTP]
- H04L67/025—Protocols based on web technology, e.g. hypertext transfer protocol [HTTP] for remote control or remote monitoring of applications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/01—Protocols
- H04L67/12—Protocols specially adapted for proprietary or special-purpose networking environments, e.g. medical networks, sensor networks, networks in vehicles or remote metering networks
- H04L67/125—Protocols specially adapted for proprietary or special-purpose networking environments, e.g. medical networks, sensor networks, networks in vehicles or remote metering networks involving control of end-device applications over a network
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N23/00—Cameras or camera modules comprising electronic image sensors; Control thereof
- H04N23/60—Control of cameras or camera modules
- H04N23/695—Control of camera direction for changing a field of view, e.g. pan, tilt or based on tracking of objects
-
- B—PERFORMING OPERATIONS; TRANSPORTING
- B65—CONVEYING; PACKING; STORING; HANDLING THIN OR FILAMENTARY MATERIAL
- B65F—GATHERING OR REMOVAL OF DOMESTIC OR LIKE REFUSE
- B65F1/00—Refuse receptacles; Accessories therefor
- B65F1/0033—Refuse receptacles; Accessories therefor specially adapted for segregated refuse collecting, e.g. receptacles with several compartments; Combination of receptacles
- B65F2001/008—Means for automatically selecting the receptacle in which refuse should be placed
-
- B—PERFORMING OPERATIONS; TRANSPORTING
- B65—CONVEYING; PACKING; STORING; HANDLING THIN OR FILAMENTARY MATERIAL
- B65F—GATHERING OR REMOVAL OF DOMESTIC OR LIKE REFUSE
- B65F2210/00—Equipment of refuse receptacles
- B65F2210/138—Identification means
-
- B—PERFORMING OPERATIONS; TRANSPORTING
- B65—CONVEYING; PACKING; STORING; HANDLING THIN OR FILAMENTARY MATERIAL
- B65F—GATHERING OR REMOVAL OF DOMESTIC OR LIKE REFUSE
- B65F2210/00—Equipment of refuse receptacles
- B65F2210/162—Pressing means
-
- Y—GENERAL 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
- Y02—TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
- Y02W—CLIMATE CHANGE MITIGATION TECHNOLOGIES RELATED TO WASTEWATER TREATMENT OR WASTE MANAGEMENT
- Y02W90/00—Enabling technologies or technologies with a potential or indirect contribution to greenhouse gas [GHG] emissions mitigation
Landscapes
- Engineering & Computer Science (AREA)
- Physics & Mathematics (AREA)
- Theoretical Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Data Mining & Analysis (AREA)
- Mathematical Physics (AREA)
- General Engineering & Computer Science (AREA)
- Life Sciences & Earth Sciences (AREA)
- Computing Systems (AREA)
- Signal Processing (AREA)
- Computer Networks & Wireless Communication (AREA)
- General Health & Medical Sciences (AREA)
- Artificial Intelligence (AREA)
- Business, Economics & Management (AREA)
- Software Systems (AREA)
- Health & Medical Sciences (AREA)
- Evolutionary Computation (AREA)
- Human Resources & Organizations (AREA)
- Computational Linguistics (AREA)
- Biophysics (AREA)
- Molecular Biology (AREA)
- Biomedical Technology (AREA)
- Pure & Applied Mathematics (AREA)
- Mathematical Optimization (AREA)
- Mathematical Analysis (AREA)
- Mechanical Engineering (AREA)
- Computational Mathematics (AREA)
- Entrepreneurship & Innovation (AREA)
- General Business, Economics & Management (AREA)
- Economics (AREA)
- Bioinformatics & Cheminformatics (AREA)
- Marketing (AREA)
- Operations Research (AREA)
- Quality & Reliability (AREA)
- Strategic Management (AREA)
- Tourism & Hospitality (AREA)
- Sustainable Development (AREA)
- Multimedia (AREA)
- Computer Vision & Pattern Recognition (AREA)
- Bioinformatics & Computational Biology (AREA)
Abstract
The invention discloses an intelligent garbage classification system which comprises a cloud server, a plurality of intelligent classification garbage cans and a plurality of mobile intelligent terminals, wherein the cloud server is used for storing a plurality of garbage cans; the intelligent classification garbage can has two working modes of manual classification and automatic classification; in the automatic classification mode, the intelligent classification garbage can end uploads the collected garbage images to the cloud server for processing to obtain the classification of the garbage, then the intelligent classification garbage can puts the garbage into a corresponding garbage bin, and finally a control panel and a mobile small program prompt a classification result. The invention also discloses a garbage recognition model based on decision tree supervision learning, so that the garbage can be intelligently classified to recognize garbage offline, and the application range of the system is greatly expanded. The garbage classification system can intelligently and automatically complete garbage classification, solves the problems of high manufacturing cost, low intelligent degree, poor recognition effect and the like of the conventional equipment, and is suitable for large-scale popularization and application.
Description
Technical Field
The invention relates to the technical field of environment-friendly equipment, in particular to an intelligent garbage classification system.
Background
With the rapid development of smart cities, the living standard of residents is continuously improved, and people have increasingly strong demands on high-quality living environments and green environment-friendly society. In order to meet the increasing living demands of people, various diversified commodities and living goods are popular. Along with the increase of domestic garbage, great pressure is applied to the environment, and the phenomenon of enclosing a city by using the garbage is already generated in some cities. The garbage classification is a big factor causing environmental pollution and difficult resource recycling, and becomes an urgent problem to be solved in China.
At present, the garbage station in China adopts a centralized garbage recycling method, and residents discard household garbage to a public garbage can after collecting the household garbage. However, the problems that the awareness of garbage classification is weak and the knowledge of garbage classification is not well mastered commonly exist in residents, so that the garbage classification is not thorough. Under the push of huge market, domestic garbage classification companies such as bamboo shoots in spring after rain. In order to realize the primary classification of household garbage, although an intelligent garbage can is raised in the market at present, the development degree is not high, the automatic induction turnover cover is mainly used, garbage cannot be classified actively, the cost is high, the intelligent garbage can is not suitable for being used in families and small communities, and the garbage putting result cannot be traced or inquired. Therefore, it is imperative to design an intelligent garbage classification system which has the advantages of intelligent classification, simple operation, low manufacturing cost, inquireable classification result and suitability for large-scale popularization.
Disclosure of Invention
In order to solve the problems, the invention provides an intelligent garbage classification system, which realizes automatic garbage classification, manual garbage classification and enquiry of classification results of a movable end, solves the problems of complex structure, low mechanical efficiency, easy damage, incapability of tracing identification results, poor identification effect, no humanization and the like of the existing intelligent classification garbage can, and has the characteristics of intelligent classification, simple operation, low manufacturing cost, enquiry of results, suitability for large-scale popularization and application and the like.
In order to achieve the purpose, the invention provides the following technical scheme:
the invention provides an intelligent garbage classification system which comprises a cloud server, a plurality of intelligent classification garbage cans and a plurality of mobile intelligent terminals.
The cloud server is used for receiving, storing and processing the garbage images uploaded by the intelligent classification garbage can, returning garbage identification results to the intelligent classification garbage can after garbage identification, responding to an inquiry request from a mobile intelligent terminal, and executing data inquiry and processing services; the cloud server needs to deploy WebAPI based on image recognition; the cloud-end server runs a model for supervised learning garbage recognition based on a decision tree;
the intelligent classification garbage can is used for collecting, classifying and storing various types of garbage and transmitting garbage images to the cloud server through a network; the intelligent classification garbage can has an offline garbage identification function;
the mobile intelligent terminal runs intelligent classification garbage can matching software for inquiring historical relevant data of the intelligent classification garbage can and a user inquires classification operation of the garbage according to the garbage name; the historical relevant data of the intelligent garbage can comprises identification time, identification results and classification results;
each of the plurality of intelligently sorted trashcans includes: the device comprises a main body frame, a control module, a throwing module, a collecting module, a compressing module and a power supply module; wherein,
the releasing module, the collecting module, the compressing module and the power supply module are positioned in the main body frame.
The control module comprises a microcontroller, a first communication module, a control panel, a camera and a flash lamp; the microcontroller includes, but is not limited to, raspberry pi, NVIDIA Jetson Nano Developer Kit, online Omega2 +; the first communication module comprises but is not limited to a WIFI, 3G, 4G and 5G communication technology module; the control panel is embedded at the outer side of the main body frame, and the rest parts of the control module except the control panel are positioned in the main body frame.
The device comprises a main body frame, a compression module, a collection module, a main body frame and a control module, wherein the main body frame is internally provided with a first bearing platform in a suspended mode on the rear side of the top, the first bearing platform is provided with a microcontroller in the control module, the front side of the top in the main body frame is connected with the delivery module in a suspended mode, the lower end of the delivery module is vertically connected with the compression module, the lower portion in the main body frame is provided with the collection module, and the upper portion of the main body frame is provided with a delivery port.
The throwing module consists of a two-degree-of-freedom holder and a second bearing platform for temporarily bearing garbage; the two-degree-of-freedom cloud platform consists of a first steering engine for controlling the horizontal rotation direction and a second steering engine for controlling the pitching angle; the first steering engine and the second steering engine are vertically connected through a steering engine multifunctional support standard part, and the rotating planes of the rotating shafts of the first steering engine and the second steering engine are vertical to each other; the middle side vertical surface of the second bearing platform is connected to a standard connecting piece of a U-shaped steering engine bracket of a second steering engine for controlling the pitching angle through screws and nuts; and a layer of resistance screen is fixed on the upper surface of the second bearing platform and used for feeding back the real-time garbage position.
The camera and the flash lamp of the control module are arranged on the back face of the throwing opening and the main body frame above the second bearing platform, and the camera lens and the flash lamp face the second bearing platform.
The microcontroller of the control module is connected with the first steering engine and the second steering engine of the throwing module, the stepping motor driving module of the compression module, the pressure sensor of the compression module, the camera, the flash lamp and the control panel; the control system comprises a first steering engine, a second steering engine and a stepping motor driving module of a throwing module, wherein the positive and negative electrodes of the first steering engine and the second steering engine of the throwing module and the positive and negative electrodes of the stepping motor driving module of a compression module are connected with the positive and negative electrodes of a microcontroller of a control module; the stepping motor of the compression module is correspondingly connected to the stepping motor driving module of the compression module according to the phase and the positive and negative poles; and a signal wire of a pressure sensor of the compression module is connected to a GPIO port with digital-to-analog conversion of the microcontroller.
The collection module consists of four pull-type garbage bins with the same shape and size, the four garbage bins are respectively positioned on four side surfaces of the main body frame, and handles are arranged on the outer side surfaces of the garbage bins, so that the garbage bins can be conveniently pulled out from the periphery of the main body frame; the perimeter of the garbage bin is smaller than that of a common garbage bag by more than 2 cm; a snap ring for preventing the garbage bag from sliding off is arranged at the opening of the garbage bin, and the snap ring has the same shape as the opening of the garbage bin and can be just clamped on the garbage bin; the four garbage bins are mutually independent and are used for storing different types of garbage.
The compression module consists of a compression table, a sliding table, a stepping motor and a pressure sensor, wherein the compression table is the same as the cross section of the garbage bin in shape and smaller than the garbage bin opening in size; the sliding table is vertically connected to a rudder disc of a first rudder machine of the two-degree-of-freedom holder of the throwing module, so that the compression table can horizontally rotate along with the holder; the sliding table consists of a screw rod, a screw rod nut and a guide rod; the compression table is connected to the screw rod nut, and the pressure sensor is mounted on the bottom surface of the compression table; the screw rod is connected with the stepping motor through a coupler.
The power module is used for supplying power to the microcontroller of the control module.
The cloud server comprises a processor, a second communication module and a memory for storing data; the second communication module includes but is not limited to WIFI, 3G, 4G, 5G communication technology module.
A plurality of each of intelligent classification garbage bin all has two kinds of mode of manual classification and automatic classification, wherein, manual classification mode includes following step:
step S100: a user selects to press a button corresponding to the type of the garbage on the control panel, the microcontroller is awakened from a sleep state, and the color of the working state indicator lamp is converted into the color corresponding to a standby state; the color of the working mode indicator light is converted into the color corresponding to the manual classification mode;
step S110: a user pulls open the garbage throwing baffle and covers the baffle after throwing garbage, the level of the limit switch is changed after the garbage delivery baffle of the intelligent classification garbage can is closed, and the color of the working state indicator light is converted into the color corresponding to the delivery executing state;
step S120: the control module controls the throwing module to throw the garbage into a specified garbage bin;
step S130: the classification result indicator lamp of the classification corresponding to the garbage on the control panel is turned on, after a plurality of seconds, the color of the working state indicator lamp is converted into the color corresponding to the sleep state, the working mode indicator lamp and the classification result indicator lamp are turned off, and the microcontroller enters the sleep state;
step S140: the user can inquire the identification time, the identification result and the classification result data of the intelligent classification garbage can through the mobile intelligent terminal.
The automatic classification mode comprises the following steps:
step S200: the intelligent classification garbage can is used for the first time, a first communication module and a second communication module need to be configured first, and the intelligent classification garbage can and the cloud server can be ensured to be communicated with each other;
step S210: the user presses the button of the 'automatic classification mode' on the control panel, the microcontroller is awakened from the 'sleep' state, and the color of the 'working state indicator light' is converted into the color corresponding to the 'standby' state; the color of the working mode indicator light is converted into the color corresponding to the automatic classification mode;
step S220: a user pulls open the garbage throwing baffle, covers the baffle after throwing garbage, and converts the color of the working state indicator light into the color corresponding to the delivery executing state;
step S230: the microcontroller controls the flash lamp to be turned on for a plurality of seconds, and the microcontroller controls the camera to collect garbage images on the second bearing platform;
step S240: the intelligent classification garbage can packages the shot garbage pictures and the unique ID number of the intelligent classification garbage can into a request head according to an HTTP (hyper text transport protocol) protocol after adopting base64 to code, and adopts a POST (POST position) method/GET (GET) method to request an image recognition WebAPI (web application programming interface) deployed on a cloud server, and the cloud server returns a garbage classification result inquired by the image recognition WebAPI to the intelligent classification garbage can;
step S250: the control module controls the throwing module to throw the garbage into a specified garbage bin;
step S260: the classification result indicator lamp of the classification corresponding to the garbage on the control panel is turned on, after a plurality of seconds, the color of the working state indicator lamp is converted into the color corresponding to the sleep state, the working mode indicator lamp and the classification result indicator lamp are turned off, and the microcontroller enters the sleep state;
step S270: the user can inquire the identification time, the identification result and the classification result data of the intelligent classification garbage can through the mobile intelligent terminal.
The cloud server needs to deploy WebAPI based on image recognition, wherein the WebAPI based on image recognition comprises but is not limited to Baidu AI image recognition API and Google image recognition API; a garbage classification database is built on a memory of the cloud server, and in the garbage classification database, a garbage name is used as a main key of the database, and a garbage category is used as an attribute; the processing process of the image recognition WebAPI deployed on the cloud server specifically comprises the following steps:
step S300: the cloud server receives the image data which are uploaded by the intelligent garbage bin and are encoded by base64 and the ID number of the intelligent garbage bin;
step S310: the cloud server calls an image recognition API (application program interface) by using the image data coded by the base64, and the cloud server obtains a returned JSON format garbage recognition result;
step S320: the cloud server analyzes the JSON format to obtain multiple groups of recognition results of the garbage and similarity of the recognition results;
step S330: selecting a garbage name result with the highest recognition similarity analyzed from the JSON format result in the step S320;
step S340: inquiring the garbage name with the highest similarity in the garbage classification database according to the determined garbage name with the highest similarity in the step S330, and if the database does not have the garbage name data, creating a dictionary tree for fuzzy matching; if no data exists, selecting the garbage name with the second highest recognition similarity analyzed from the JSON format result in the step S320;
step S350: repeating the operation of the step S340 until a final classification result is inquired;
step S360: the cloud server returns the garbage inquiry classification result to the intelligent classification garbage can; the cloud server stores a final garbage recognition result (including information such as recognition time, a recognition result and a classification result) in a result table of a database corresponding to an ID number of the intelligent garbage can, historical data deployed on the cloud server can be used for inquiring WebAPI, a mobile terminal applet on the mobile intelligent terminal can obtain historical data information of the intelligent garbage can by calling the WebAPI through calling the historical data corresponding to the ID number of the intelligent garbage can, and the inquired historical data information includes the recognition time, the recognition result and the classification result.
The cloud server collects images uploaded from the intelligent garbage can and identification result labels, and trains a garbage identification model based on decision-tree supervision learning for garbage image identification under the offline state of the garbage can, wherein the garbage identification model based on decision-tree supervision learning specifically comprises the following steps:
step S400: creating a picture training set with the same garbage, and performing approximate whitening processing on the picture to make the model insensitive to the dynamic range change of the picture;
step S410: creating a convolutional neural network model comprising an input layer, a multi-layer convolutional neural network layer, a first fully-connected layer based on modified linear activation, a second fully-connected layer based on modified linear activation, a Softmax regression model, wherein:
the Softmax regression model normalizes a probability distribution derived for a second fully-connected layer based on modified linear activation, the normalization formula being:
in the formula, xiRepresenting the ith element of the array x, wherein the group is a subscript set of all elements of the array x;
step S420: merging the garbage picture training sets with relatively more similar characteristics;
step S430: performing picture compression on pictures in the spam picture training set, wherein the image compression method comprises but is not limited to an image compression technology based on singular value decomposition, an EZW coding algorithm and an SPIHT coding algorithm;
step S440: respectively carrying out a back propagation training process on each training set to obtain an nth layer node model;
step S450: repeating the steps S410-S440 to obtain an (n-1) -th layer node model until all the spam picture training sets are obtained and combined, training the garbage picture training sets into a first layer model with only one root model, and jumping to the step S460 to continue execution;
step S460: and integrating the models of 1 to n layers into a decision tree according to the hierarchical structure and the set correlation, and finishing the establishment of the overall model.
In step S400, performing approximate whitening processing on the picture specifically includes the following steps:
step S401: calculating the mean value and the variance of the original image, and assuming that the image P has I lines and J columns, the image mean value formula is as follows:
the image variance formula is:
in the formula, pijRepresenting the pixel values of the image in i rows and j columns;
step S402: converting the pixel value, wherein the conversion formula is as follows:
in the formula, xijRepresenting the transformed pixel values of the image in i rows and j columns.
In step S410, the plurality of convolutional neural network layers include a convolutional layer, an excitation layer, a pooling layer, and a local response normalization layer, wherein,
The maximum pooling operator formula of the pooling layer isWherein y is an element contained in the local acceptance domain;
the local response normalization formula of the local response normalization layer is as follows:
in the formula,is the output of the ith convolution kernel at the (x, y) position,is the input of the ith convolution kernel at the (x, y) position, N is the number of convolution kernels, N is the number of adjacent convolution kernels added with normalization calculation, and the parameters k, N, alpha and beta are all hyper-parameters.
The step S420 further includes the steps of:
step S421: averaging the image matrixes of the image training sets to obtain an average matrix of each training set;
step S422: calculating Euclidean distances among the mean value matrixes, wherein the Euclidean distances are represented by the following formula:
where M is the column dimension of the mean matrix, N is the row dimension of the mean matrix, x and y are different mean matrices, xjiAnd yjiJ columns and i rows of elements in the mean value matrix are represented;
step S423: sorting the Euclidean distances among the training sets from small to large;
step S424: and merging the training sets corresponding to the smaller Euclidean distance.
In step S440, the back propagation training process specifically includes the following steps:
step S441: initializing weight and bias: randomly assigning a set of smaller non-zero values to the weight w and the bias b;
step S442: inputting a training sample;
step S443: the forward propagation process: calculating the output of the network according to the input of a given convolutional neural network model, finally obtaining the estimated probability, and calculating the cross entropy, wherein the cross entropy formula is as follows:
in the formula, piRepresenting the true probability distribution of each of the spam,estimating probability distribution;
when the cross entropy is less than the desired value, step S444 is performed; otherwise, returning to step S445;
step S444: and (3) a back propagation process: minimizing the cross entropy by using a gradient descent method at a preset learning rate, so that each variable moves towards the direction of continuously reducing the cost, namely the network can adaptively adjust the weight and the bias of each layer, and returning to the step S443; the gradient descent method formula is as follows:
in the formula, E is an error function, namely cross entropy, eta is a learning rate which is a hyper-parameter, k is training iteration times, and theta is a weight or a bias;
step S445: and finishing the node training corresponding to the training set.
The realization of the offline garbage recognition function of the intelligent garbage can specifically comprises the following steps:
step S510: the cloud server decodes the data which is uploaded by the intelligent classification garbage can and is encoded by base64 into pictures;
step S520: using the pictures and the identification result labels to train a decision tree-based supervised learning garbage identification model of the cloud server;
step S530: packaging the trained garbage recognition model into firmware to be burnt into the microcontroller;
step S540: the microcontroller operates a garbage recognition model to recognize garbage;
in step S540, the microcontroller operates the garbage recognition model to perform garbage recognition, and the method specifically includes the following steps:
step S541: inputting a picture to be identified, traversing the first layer model, and obtaining a target object type with the highest possibility;
step S542: entering a node of a next layer of the target object class of the decision tree, and continuously traversing the leaf model on the node to obtain the target object class with the highest possibility; repeating the step S542 until all the data in the sub data set belong to the same class, and continuing to execute the step S543;
step S543: and obtaining a final garbage identification result.
Compared with the prior art, the invention has the beneficial effects that:
1. the cloud server side is provided with a server side/client side (C/S) framework, the client side only plays a role in receiving and sending data, data processing is carried out on the cloud server, and operations such as garbage identification and the like which need a large amount of calculation are uploaded to the cloud server side by the microcontroller for processing, so that the identification efficiency is improved, the performance requirement on the microcontroller is reduced, in addition, the C/S framework is more beneficial to technical and requirement updating, and only WebAPI codes deployed on the server need to be modified;
2. the identification result can be traced, and the mobile intelligent terminal can inquire the history data (identification time, identification result, classification result and the like) of the garbage can according to the unique ID number of the intelligent classification garbage can;
3. the decision tree supervised learning algorithm is based on a tree structure, the article identification range is easier to expand on the original model, only data sets or node related nodes are required to be updated and added, the whole model is not required to be trained from the beginning, the calculated amount is reduced, and the reduction of identification accuracy due to the addition of global training is avoided;
4. collecting pictures uploaded by the microcontroller and corresponding identification result labels, training a local garbage identification model of the server by using a decision tree supervised learning algorithm, packaging the trained model into firmware and burning the firmware into the microcontroller, realizing garbage identification in a network-free environment and widening the application scenes of the intelligent garbage classification system;
5. the invention has the advantages of reasonable structural design, simple operation and low manufacturing cost, is suitable for large-scale popularization and application, is beneficial to environmental protection and resource recycling, and realizes energy conservation, emission reduction, low carbon and environmental protection.
Drawings
FIG. 1 is a physical architecture diagram of an embodiment of the present invention;
FIG. 2 is a schematic perspective view of an intelligent classification trash can according to an embodiment of the present invention;
FIG. 3 is a schematic structural diagram of the back of a feeding opening of an intelligent classification garbage can in the embodiment of the invention;
FIG. 4 is a schematic structural diagram of a throwing module and a compressing module of the intelligent classification garbage can in the embodiment of the invention;
the parts in the drawings are numbered as follows:
1-a main body frame, 3-a throwing module, 4-a collecting module, 5-a compressing module, 101-a first bearing platform, 102-a throwing port baffle, 105-a limit switch, 201-a control panel, 202-a microcontroller, 203-a camera, 204-a flashlight, 301-a second bearing platform, 302-a first steering engine, 303-a second steering engine, 304-a U-shaped steering engine bracket standard connecting piece, 305-a resistance screen, 401-a garbage bin, 402-a garbage bag clamping ring, 501-a compressing table, 502-a sliding table, 5021-a lead screw, 5022-a lead screw nut and 5023-a guide rod.
Detailed Description
In order to make the technical solution, the structural features, the achieved objects and the advantages of the present invention more apparent, the present invention will be described in further detail with reference to the following specific embodiments in conjunction with the accompanying drawings. It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.
Fig. 1 is a schematic physical architecture diagram of an intelligent garbage classification system according to a preferred embodiment of the present invention. This embodiment has included cloud end server, a plurality of intelligent classification garbage bin and a plurality of mobile intelligent terminal.
The cloud server is used for receiving, storing and processing the garbage images uploaded by the intelligent classification garbage can, returning garbage identification results to the intelligent classification garbage can after garbage identification, responding to an inquiry request from a mobile intelligent terminal, and executing data inquiry and processing services; the cloud server needs to deploy WebAPI based on image recognition; the cloud-end server runs a model for supervised learning garbage recognition based on a decision tree;
the intelligent classification garbage can is used for collecting, classifying and storing various types of garbage and transmitting garbage images to the cloud server through a network; the intelligent classification garbage can has an offline garbage identification function;
the mobile intelligent terminal runs intelligent classification garbage can matching software for inquiring historical relevant data of the intelligent classification garbage can and a user inquires classification operation of the garbage according to the garbage name; the historical relevant data of the intelligent garbage can comprises identification time, identification results and classification results;
each of the plurality of intelligently sorted trashcans includes: the device comprises a main body frame (1), a control module, a throwing module (3), a collecting module (4), a compressing module (5) and a power supply module; wherein,
the releasing module (3), the collecting module (4), the compressing module (5) and the power supply module are positioned in the main body frame (1). Preferably, the main body frame adopts 2020 European standard aluminium alloy to build, and the aluminium alloy right angle is connected and is adopted supporting angular groove standard connecting piece, and other angle section bar connection adopt supporting arbitrary angle standard connecting piece, and when connecting other modules on the main body frame, the adoption is corresponding to the installation aluminium alloy recess position and is laid elastic nut, then screws the bolt of other modules on elastic nut.
The control module comprises a microcontroller (202), a first communication module, a control panel (201), a camera (203) and a flash lamp (204), wherein the microcontroller (202) comprises, but is not limited to, a raspberry pi, NVIDIA Jetson Nano device Kit, and on Omega2 +; the first communication module comprises but is not limited to a WIFI, 3G, 4G and 5G communication technology module; the control panel (201) is embedded outside the main body frame (1), and the rest parts of the control module except the control panel (201) are positioned inside the main body frame (1). The microcontroller (202) preferably selects raspberry pi 3B +, the camera (203) preferably selects raspberry pi to be matched with a 500-ten-thousand-pixel CSI camera module, the camera module is connected with the raspberry pi through a 15Pin flat cable, and the flash lamp (204) preferably selects white.
The device comprises a main body frame (1), wherein a first bearing platform (101) is installed on the rear side of the top inside the main body frame (1) in a hanging mode, a microcontroller (202) in a control module is installed on the first bearing platform (101), the front side of the top inside the main body frame (1) is connected with a throwing module (3) in a hanging mode, the lower end of the throwing module (3) is connected with a compression module (5) vertically, a collecting module (4) is installed on the lower portion inside the main body frame (1), and a throwing port is formed in the upper portion of the main body frame (1).
The throwing module (3) consists of a two-degree-of-freedom holder and a second bearing platform (301) for temporarily bearing garbage; preferably, the second bearing platform (301) is in a hopper shape with a rectangle cut along a diagonal line, the vertical faces of the left side and the right side are right-angled triangles with equal size, and the vertical face of the rear side and the bottom face are rectangles; the two-degree-of-freedom holder consists of a first steering engine (302) for controlling the horizontal rotation direction and a second steering engine (303) for controlling the pitching angle; the first steering engine (302) and the second steering engine (303) are vertically connected through a steering engine multifunctional support standard part, and the rotating planes of the rotating shafts of the first steering engine (302) and the second steering engine (303) are vertical to each other; the middle side vertical surface of the second bearing platform (301) is connected to a U-shaped steering engine support standard connecting piece (304) of a second steering engine for controlling the pitching angle through screws and nuts; and a layer of resistive screen (305) is fixed on the upper surface of the second bearing platform and used for feeding back the real-time position of the garbage.
The camera (203) and the flash lamp (204) of the control module are arranged on the back of the throwing opening and on the main body frame (1) above the second bearing platform (301), and the lens of the camera (203) and the flash lamp (204) are right opposite to the second bearing platform (301).
The microcontroller (202) of the control module is connected with a first steering engine (302) and a second steering engine (303) of the putting module (3), a stepping motor driving module of the compression module (5), a pressure sensor of the compression module (5), the camera (203), the flash lamp (204) and the control panel (201); the control system comprises a first steering engine (302), a second steering engine (303) and a compression module (5) of the throwing module (3), wherein the positive and negative poles of a stepping motor driving module of the compression module (5) are connected with the positive and negative poles of a microcontroller (202) of the control module, signal lines of the first steering engine (302) and the second steering engine (303) of the throwing module (3) for receiving PWM signals are connected with GPIO ports with PWM functions of the microcontroller (202), and a control line of the stepping motor driving module of the compression module (5) is connected with common GPIO ports of the microcontroller (202); the stepping motor of the compression module (5) is correspondingly connected to the stepping motor driving module of the compression module (5) according to the phase and the positive and negative poles; and a signal wire of a pressure sensor of the compression module (5) is connected to a GPIO port with digital-to-analog conversion of the microcontroller (202), and the pressure sensor preferably adopts a film pressure sensor.
The collection module (4) is composed of four drawing type garbage bins (401) which are identical in shape and size, the four garbage bins (401) are respectively located on four side faces of the main body frame (1), a handle is arranged on the outer side surface of each garbage bin (401), and the garbage bins (401) can be conveniently drawn out from the periphery of the main body frame (1); the perimeter of the garbage bin (401) is smaller than that of a common garbage bag by more than 2 cm; a snap ring (402) for preventing the garbage bag from sliding off is arranged at the bin opening of the garbage bin (401), and the snap ring (402) has the same shape as the garbage bin opening and can be just clamped on the garbage bin (401); the four waste bins (401) are independent of each other for storing different types of waste, preferably classified into dry waste, wet waste, hazardous waste and recyclable waste.
The compression module (5) consists of a compression table (501) which has the same shape as the cross section area of the garbage bin and is smaller than the size of the garbage bin opening, a sliding table (502), a stepping motor and a pressure sensor; the sliding table (502) is vertically connected to a rudder disc of a first steering engine (302) of the two-degree-of-freedom holder of the putting module (3), so that the compression table (501) can horizontally rotate along with the holder; the sliding table (502) is composed of a screw rod (5021), a screw rod nut (5022) and a guide rod (5023); the compression table (501) is connected to the screw nut (5022), and the pressure sensor is mounted on the bottom surface of the compression table (501); the screw rod (5021) is connected with the stepping motor through a coupler.
The power module primarily powers the microcontroller (202), preferably using a 5v power supply or being connected to a 220 volt power supply via a power adapter.
The cloud server comprises a processor, a second communication module and a memory for storing data; the second communication module includes but is not limited to WIFI, 3G, 4G, 5G and other communication technology modules.
A plurality of each of intelligent classification garbage bin all has two kinds of mode of manual classification and automatic classification, wherein, manual classification mode includes following step:
step S100: a user selects and presses a button corresponding to the category of the garbage on a control panel (201), the microcontroller (202) is awakened from a sleep state, and the color of the working state indicator light is converted into the color corresponding to a standby state; the color of the working mode indicator light is converted into a color corresponding to the manual classification mode;
step S110: a user pulls open the garbage throwing baffle (102) and covers the baffle (102) after throwing garbage, the level of a limit switch (105) is changed after the garbage delivery baffle (102) of the intelligent classification garbage can is closed, and the color of the working state indicator light is converted into the color corresponding to the delivery executing state;
step S120: the control module controls the throwing module (3) to throw the garbage into a specified garbage bin (401);
step S130: the classification result indicator lamps of the categories corresponding to the garbage on the control panel (201) are turned on, after a plurality of seconds, the colors of the working state indicator lamps are converted into the colors corresponding to the sleep state, the working mode indicator lamps and the classification result indicator lamps are turned off, and the microcontroller enters the sleep state;
step S140: the user can inquire data such as the identification time, the identification result and the classification result of the intelligent classification garbage can through the mobile intelligent terminal.
The automatic classification mode comprises the following steps:
step S200: the intelligent classification garbage can is used for the first time, a first communication module and a second communication module need to be configured first, and the intelligent classification garbage can and the cloud server can be ensured to be communicated with each other;
step S210: the user presses a button of an 'automatic classification mode' on a control panel (201), the microcontroller (202) is awakened from a 'sleep' state, and the color of the 'working state indicator light' is converted into the color corresponding to a 'standby' state; the color of the working mode indicator light is converted into the color corresponding to the automatic classification mode;
step S220: the user pulls open the garbage throwing baffle (102) and covers the baffle (102) after throwing garbage, and the color of the working state indicating lamp is converted into the color corresponding to the delivery executing state;
step S230: the microcontroller (202) controls a flash lamp (204) to be turned on for a plurality of seconds, and the microcontroller controls the camera (203) to acquire a garbage image on the second bearing platform (301);
step S240: the intelligent classification garbage can packages the shot garbage pictures and the unique ID number of the intelligent classification garbage can into a request head according to an HTTP (hyper text transport protocol) protocol after adopting base64 to code, and adopts a POST (POST position) method/GET (GET) method to request an image recognition WebAPI (web application programming interface) deployed on a cloud server, and the cloud server returns a garbage classification result inquired by the image recognition WebAPI to the intelligent classification garbage can;
step S250: the control module controls the throwing module to throw the garbage into a specified garbage bin;
step S260: the classification result indicating lamp of the classification corresponding to the garbage on the control panel (201) is turned on, after a plurality of seconds, the color of the working state indicating lamp is converted into the color corresponding to the sleep state, the working mode indicating lamp and the classification result indicating lamp are turned off, and the microcontroller (202) enters the sleep state;
step S270: the user can inquire the identification time, the identification result and the classification result data of the intelligent classification garbage can through the mobile intelligent terminal.
The cloud server needs to deploy WebAPI based on image recognition, wherein the WebAPI based on image recognition comprises but is not limited to Baidu AI image recognition API and Google image recognition API; a garbage classification database is built on a memory of the cloud server, and in the garbage classification database, a garbage name is used as a main key of the database, and a garbage category is used as an attribute; the processing process of the image recognition WebAPI deployed on the cloud server specifically comprises the following steps:
step S300: the cloud server receives the image data which are uploaded by the intelligent garbage bin and are encoded by base64 and the ID number of the intelligent garbage bin;
step S310: the cloud server calls an image recognition API (application program interface) by using the image data coded by the base64, and the cloud server obtains a returned JSON format garbage recognition result;
step S320: the cloud server analyzes the JSON format to obtain multiple groups of recognition results of the garbage and similarity of the recognition results;
step S330: selecting a garbage name result with the highest recognition similarity analyzed from the JSON format result in the step S320;
step S340: inquiring the garbage name with the highest similarity in the garbage classification database according to the determined garbage name with the highest similarity in the step S330, and if the database does not have the garbage name data, creating a dictionary tree for fuzzy matching; if no data exists, selecting the garbage name with the second highest recognition similarity analyzed from the JSON format result in the step S320;
step S350: repeating the operation of the step S340 until a final classification result is inquired;
step S360: the cloud server returns the garbage inquiry classification result to the intelligent classification garbage can; the cloud server stores a final garbage recognition result (including information such as recognition time, a recognition result and a classification result) in a result table of a database corresponding to an ID number of the intelligent garbage can, historical data deployed on the cloud server can be used for inquiring WebAPI, a mobile terminal applet on the mobile intelligent terminal can obtain historical data information of the intelligent garbage can by calling the WebAPI through calling the historical data corresponding to the ID number of the intelligent garbage can, and the inquired historical data information includes the recognition time, the recognition result and the classification result.
The cloud server collects images uploaded from the intelligent garbage can and identification result labels, and trains a garbage identification model based on decision-tree supervision learning for garbage image identification under the offline state of the garbage can, wherein the garbage identification model based on decision-tree supervision learning specifically comprises the following steps:
step S400: creating a picture training set with the same garbage, and performing approximate whitening processing on the picture to make the model insensitive to the dynamic range change of the picture;
step S410: creating a convolutional neural network model comprising an input layer, a multi-layer convolutional neural network layer, a first fully-connected layer based on modified linear activation, a second fully-connected layer based on modified linear activation, a Softmax regression model, wherein:
the Softmax regression model normalizes a probability distribution derived for a second fully-connected layer based on modified linear activation, the normalization formula being:
in the formula, xiThe ith element of the array x is represented, and group is the whole array xThe subscript set of the elements and the Softmax regression model are used for mapping actual values to be between 0 and 1 to form a list, and the values in the list are added to be 1 to achieve the effects of normalization, amplification and hashing;
step S420: merging the garbage picture training sets with relatively more similar characteristics;
step S430: performing picture compression on pictures in the spam picture training set, wherein the image compression method comprises but is not limited to an image compression technology based on singular value decomposition, an EZW coding algorithm and an SPIHT coding algorithm;
step S440: respectively carrying out a back propagation training process on each training set, and obtaining an nth layer node model after training is completed;
step S450: repeating the steps S410-S440 to obtain an (n-1) -th layer node model until all the spam picture training sets are obtained and combined, training the garbage picture training sets into a first layer model with only one root model, and jumping to the step S460 to continue execution;
step S460: and integrating the models of 1 to n layers into a decision tree according to the hierarchical structure and the set correlation, and finishing the establishment of the overall model.
In step S400, performing approximate whitening processing on the picture specifically includes the following steps:
step S401: calculating the mean value and the variance of the original image, and assuming that the image P has I lines and J columns, the image mean value formula is as follows:
the image variance formula is:
in the formula, pijRepresenting the pixel values of the image in i rows and j columns;
step S402: converting the pixel value, wherein the conversion formula is as follows:
in the formula, xijRepresenting the transformed pixel values of the image in i rows and j columns.
In step S410, the plurality of convolutional neural network layers include a convolutional layer, an excitation layer, a pooling layer, and a local response normalization layer, wherein,
the activation function of the excitation layer isCarrying out nonlinear mapping on the output result of the convolutional layer;
the pooling layer removes redundant information by using a maximum pooling operator (max-pooling), wherein the formula of the maximum pooling operator isWherein y is an element contained in the local acceptance domain, namely, a point with the maximum value in the local acceptance domain is taken to avoid the fuzzification effect of average pooling;
the local response normalization layer simulates a competitive mechanism that the inhibition phenomenon (lateral inhibition) of a biologically active neuron to an adjacent neuron creates a neuron with a larger gain response to the activity of the local neuron and inhibits other neurons with smaller feedback, and enhances the generalization capability of the model, wherein the local response normalization formula is as follows:
in the formula,is the output of the ith convolution kernel at the (x, y) position,is the input of the ith convolution kernel at the (x, y) position, N is the number of convolution kernels, N is the number of adjacent convolution kernels added with normalization calculation, andthe numbers k, n, α, β are all hyperparameters.
In step S420, merging the spam picture training sets with relatively closer features, specifically including the following steps:
step S421: averaging the image matrixes of the image training sets to obtain an average matrix of each training set;
step S422: calculating Euclidean distances among the mean value matrixes, wherein the Euclidean distances are represented by the following formula:
where M is the column dimension of the mean matrix, N is the row dimension of the mean matrix, x and y are different mean matrices, xjiAnd yjiJ columns and i rows of elements in the mean value matrix are represented;
step S423: sorting the Euclidean distances among the training sets from small to large;
step S424: and merging the training sets corresponding to the smaller Euclidean distance.
In step S440, the back propagation training process specifically includes the following steps:
step S441: initializing weight and bias: randomly assigning a set of smaller non-zero values to the weight w and the bias b;
step S442: inputting a training sample;
step S443: the forward propagation process: calculating the output of the network according to the input of a given convolutional neural network model, finally obtaining the estimated probability, and calculating the cross entropy, wherein the cross entropy formula is as follows:
in the formula, piRepresenting the true probability distribution of each of the spam,estimating probability distribution;
when the cross entropy is less than the desired value, step S444 is performed; otherwise, returning to step S445;
step S444: and (3) a back propagation process: minimizing the cross entropy by using a gradient descent method at a preset learning rate, so that each variable moves towards the direction of continuously reducing the cost, namely the network can adaptively adjust the weight and the bias of each layer, and returning to the step S443; the gradient descent method formula is as follows:
in the formula, E is an error function, namely cross entropy, eta is a learning rate which is a hyper-parameter, k is training iteration times, and theta is a weight or a bias;
step S445: and finishing the node training corresponding to the training set.
The realization of the offline garbage recognition function of the intelligent garbage can specifically comprises the following steps:
step S510: the cloud server decodes the data which is uploaded by the intelligent classification garbage can and is encoded by base64 into pictures;
step S520: using the pictures and the identification result labels to train a decision tree-based supervised learning garbage identification model of the cloud server;
step S530: packaging the trained garbage recognition model into firmware to be burnt into a microcontroller (202);
step S540: the microcontroller (202) runs a garbage recognition model to perform garbage recognition.
In the step S540, the microcontroller (202) runs the garbage recognition model to perform garbage recognition, which specifically includes the following steps:
step S541: inputting a picture to be identified, traversing the first layer model, and obtaining a target object type with the highest possibility;
step S542: entering a node of a next layer of the target object class of the decision tree, and continuously traversing the leaf model on the node to obtain the target object class with the highest possibility; repeating the step S542 until all the data in the sub data set belong to the same class, and continuing to execute the step S543;
step S543: and obtaining a final garbage identification result.
It should be noted that the terms "upper", "lower", "inner", "outer", "front", "rear", etc. indicate orientations or positional relationships based on those shown in the drawings, and are only for convenience of describing the present invention and simplifying the description, but do not indicate or imply that the indicated device or element must have a specific orientation, and thus, should not be construed as limiting the present invention.
The above description is only an embodiment of the present invention, and not intended to limit the scope of the present invention, and all modifications of equivalent structures and equivalent processes performed by the present specification and drawings, or directly or indirectly applied to other related technical fields, are included in the scope of the present invention.
Claims (6)
1. An intelligent garbage classification system is characterized by comprising a cloud server, a plurality of intelligent classification garbage cans and a plurality of mobile intelligent terminals;
the cloud server is used for receiving, storing and processing the garbage images uploaded by the intelligent classification garbage can, returning a garbage recognition result to the intelligent classification garbage can after garbage recognition, responding to a query request from a mobile intelligent terminal, and executing data query and processing service; the cloud server needs to deploy WebAPI based on image recognition; the cloud server runs a supervised learning garbage identification model based on a decision tree;
the intelligent classification garbage can is used for collecting, classifying and storing various types of garbage and transmitting garbage images to the cloud server through a network; the intelligent classification garbage can has an offline garbage identification function;
the mobile intelligent terminal runs intelligent classification garbage can matching software for inquiring historical relevant data of the intelligent classification garbage can and a user inquires classification operation of the garbage according to the garbage name; the historical relevant data of the intelligent garbage can comprises identification time, identification results and classification results;
each of the plurality of intelligently sorted trashcans includes: the device comprises a main body frame, a control module, a throwing module, a collecting module, a compressing module and a power supply module; wherein,
the throwing module, the collecting module, the compressing module and the power supply module are positioned inside the main body frame;
the control module comprises a microcontroller, a first communication module, a control panel, a camera and a flash lamp; the microcontroller includes, but is not limited to, raspberry pi, NVIDIA Jetson Nano Developer Kit, online Omega2 +; the first communication module comprises but is not limited to a WIFI, 3G, 4G and 5G communication technology module; the control panel is embedded outside the main body frame, and the rest parts of the control module except the control panel are positioned inside the main body frame;
a first bearing platform is installed on the rear side of the top inside the main body frame in a hanging mode, a microcontroller in the control module is installed on the first bearing platform, the throwing module is connected to the front side of the top inside the main body frame in a hanging mode, the lower end of the throwing module is vertically connected with the compression module, the collection module is installed on the lower portion inside the main body frame, and a throwing port is formed in the upper portion of the main body frame;
the throwing module consists of a two-degree-of-freedom holder and a second bearing platform for temporarily bearing garbage; the two-degree-of-freedom holder consists of a first steering engine for controlling the horizontal rotation direction and a second steering engine for controlling the pitching angle; the first steering engine and the second steering engine are vertically connected through a steering engine multifunctional support standard part, and the rotating planes of the rotating shafts of the first steering engine and the second steering engine are vertical to each other; the middle side vertical surface of the second bearing platform is connected to a standard connecting piece of a U-shaped steering engine bracket of a second steering engine for controlling the pitching angle through screws and nuts; a layer of resistance screen is fixed on the upper surface of the second bearing platform and used for feeding back the real-time position of the garbage;
the camera and the flash lamp of the control module are arranged on the back surface of the throwing port and the main body frame above the second bearing platform, and the camera lens and the flash lamp face the second bearing platform;
the microcontroller of the control module is connected with the first steering engine and the second steering engine of the throwing module, the stepping motor driving module of the compression module, the pressure sensor of the compression module, the camera, the flash lamp and the control panel; the control circuit comprises a feeding module, a microcontroller, a compression module, a first steering engine, a second steering engine, a stepping motor driving module, a signal wire, a GPIO port with a PWM function, a control wire and a control wire, wherein the positive and negative electrodes of the first steering engine and the second steering engine of the feeding module and the positive and negative electrodes of the stepping motor driving module of the compression module are connected with the positive and negative electrodes of the microcontroller of the control module; the stepping motor of the compression module is correspondingly connected to the stepping motor driving module of the compression module according to the phase and the positive and negative poles; the signal wire of the pressure sensor of the compression module is connected to a GPIO port with digital-to-analog conversion of the microcontroller;
the collection module consists of four pull-type garbage bins which are same in shape and size, the four garbage bins are respectively positioned on four side surfaces of the main body frame, and handles are arranged on the outer side surfaces of the garbage bins, so that the garbage bins can be conveniently pulled out from the periphery of the main body frame; the perimeter of the garbage bin is smaller than that of a common garbage bag by more than 2 cm; a snap ring for preventing the garbage bag from sliding off is arranged at the opening of the garbage bin, and the snap ring has the same shape as the opening of the garbage bin and can be just clamped on the garbage bin; the four garbage bins are mutually independent and are used for storing different types of garbage;
the compression module consists of a compression table, a sliding table, a stepping motor and a pressure sensor, wherein the compression table is the same as the cross section of the garbage bin in shape and smaller than the garbage bin opening in size; the sliding table is vertically connected to a steering wheel of a first steering engine of the two-degree-of-freedom holder of the throwing module, so that the compression table can horizontally rotate along with the holder; the sliding table consists of a screw rod, a screw rod nut and a guide rod; the compression table is connected to the screw rod nut, and the pressure sensor is mounted on the bottom surface of the compression table; the screw rod is connected with the stepping motor through a coupler;
the power supply module is used for supplying power to the microcontroller of the control module;
the cloud server comprises a processor, a second communication module and a memory for storing data; the second communication module includes but is not limited to WIFI, 3G, 4G, 5G communication technology modules.
2. The intelligent garbage classification system according to claim 1, wherein each of the plurality of intelligent classification garbage cans has two operation modes of manual classification and automatic classification, wherein the manual classification mode comprises the following steps:
step S100: a user selects to press a button corresponding to the type of the garbage on the control panel, the microcontroller is awakened from a sleep state, and the color of the working state indicator lamp is converted into the color corresponding to a standby state; the color of the working mode indicator light is converted into a color corresponding to the manual classification mode;
step S110: a user pulls open the garbage throwing baffle and covers the baffle after throwing garbage, the level of the limit switch is changed after the garbage delivery baffle of the intelligent classification garbage can is closed, and the color of the working state indicator light is converted into the color corresponding to the delivery executing state;
step S120: the control module controls the throwing module to throw the garbage into a specified garbage bin;
step S130: the classification result indicator lamp of the classification corresponding to the garbage on the control panel is turned on, after a plurality of seconds, the color of the working state indicator lamp is converted into the color corresponding to the sleep state, the working mode indicator lamp and the classification result indicator lamp are turned off, and the microcontroller enters the sleep state;
step S140: a user can inquire the identification time, the identification result and the classification result data of the intelligent classification garbage can through the mobile intelligent terminal;
the automatic classification mode comprises the following steps:
step S200: the intelligent classification garbage can is used for the first time, a first communication module and a second communication module need to be configured first, and the intelligent classification garbage can and the cloud server can be ensured to be communicated with each other;
step S210: the user presses the button of the 'automatic classification mode' on the control panel, the microcontroller is awakened from the 'sleep' state, and the color of the 'working state indicator light' is converted into the color corresponding to the 'standby' state; the color of the working mode indicator light is converted into the color corresponding to the automatic classification mode;
step S220: a user pulls open the garbage throwing baffle, covers the baffle after throwing garbage, and converts the color of the working state indicator light into the color corresponding to the delivery executing state;
step S230: the microcontroller controls the flash lamp to be turned on for a plurality of seconds, and the microcontroller controls the camera to acquire a garbage image on the second bearing platform;
step S240: the intelligent classification garbage can packages the shot garbage pictures and the unique ID number of the intelligent classification garbage can into a request head according to an HTTP (hyper text transport protocol) protocol after the shot garbage pictures are coded by adopting base64, a POST (POST position) method/GET (GET) method is adopted to request an image recognition WebAPI (web application program interface) deployed on a cloud server, and the cloud server returns a garbage classification result inquired by the image recognition WebAPI to the intelligent classification garbage can;
step S250: the control module controls the throwing module to throw the garbage into a specified garbage bin;
step S260: the classification result indicator lamp of the classification corresponding to the garbage on the control panel is turned on, after a plurality of seconds, the color of the working state indicator lamp is converted into the color corresponding to the sleep state, the working mode indicator lamp and the classification result indicator lamp are turned off, and the microcontroller enters the sleep state;
step S270: the user can inquire the identification time, the identification result and the classification result data of the intelligent classification garbage can through the mobile intelligent terminal.
3. The intelligent garbage classification system of claim 1, wherein the cloud server is deployed with webapis based on image recognition, including but not limited to Baidu AI image recognition API, Google image recognition API; a garbage classification database is built on a memory of the cloud server, wherein a garbage name is used as a main key of the database, and a garbage category is used as an attribute in the garbage classification database; the processing process of the image recognition WebAPI deployed on the cloud server specifically comprises the following steps:
step S300: the cloud server receives the image data which are uploaded by the intelligent garbage bin and are encoded by base64 and the ID number of the intelligent garbage bin;
step S310: the cloud server calls an image recognition API (application program interface) by using the image data coded by the base64, and the cloud server obtains a returned JSON format garbage recognition result;
step S320: the cloud server analyzes the JSON format to obtain multiple groups of recognition results of the garbage and similarity of the recognition results;
step S330: selecting a garbage name result with the highest recognition similarity analyzed from the JSON format result in the step S320;
step S340: inquiring the garbage name with the highest similarity in the garbage classification database according to the determined garbage name with the highest similarity in the step S330, and if the database does not have the garbage name data, creating a dictionary tree for fuzzy matching; if the JSON format result is not data, selecting the garbage name with the second highest recognition similarity analyzed by the JSON format result in the step S320;
step S350: repeating the operation of the step S340 until a final classification result is inquired;
step S360: the cloud server returns the garbage inquiry classification result to the intelligent classification garbage can; the cloud server stores the final garbage recognition result in a result table of a database corresponding to the ID number of the intelligent garbage can, historical data deployed on the cloud server can be used for inquiring WebAPI, a mobile terminal applet on the mobile intelligent terminal can inquire WebAPI by calling the historical data corresponding to the ID number of the intelligent garbage can to obtain historical data information of the intelligent garbage can, and the inquired historical data information comprises recognition time, recognition results and classification results.
4. The intelligent garbage classification system according to claim 1, wherein the cloud server collects images and identification result labels uploaded from the intelligent garbage can to train a decision-tree-based supervised learning garbage identification model for garbage image identification of the garbage can in an offline state, and the decision-tree-based supervised learning garbage identification model specifically comprises the following steps:
step S400: creating a picture training set with the same garbage, and performing approximate whitening processing on the picture to make the model insensitive to the dynamic range change of the picture;
step S410: creating a convolutional neural network model comprising an input layer, a multi-layer convolutional neural network layer, a first fully-connected layer based on modified linear activation, a second fully-connected layer based on modified linear activation, a Softmax regression model, wherein:
the Softmax regression model normalizes a probability distribution derived for a second fully-connected layer based on modified linear activation, the normalization formula being:
in the formula, xiRepresenting the ith element of the array x, wherein the group is a subscript set of all elements of the array x;
step S420: merging the garbage picture training sets with relatively more similar characteristics;
step S430: performing picture compression on pictures in the spam picture training set, wherein the image compression method comprises but is not limited to an image compression technology based on singular value decomposition, an EZW coding algorithm and an SPIHT coding algorithm;
step S440: respectively carrying out a back propagation training process on each training set to obtain an nth layer node model;
step S450: repeating the steps S410-S440 to obtain an (n-1) -th layer node model until all the spam picture training sets are obtained and combined, training the garbage picture training sets into a first layer model with only one root model, and jumping to the step S460 to continue execution;
step S460: and integrating the models of 1 to n layers into a decision tree according to the hierarchical structure and the set correlation, and finishing the establishment of the overall model.
5. The intelligent garbage classification system according to claim 4,
in step S400, performing approximate whitening processing on the picture specifically includes the following steps:
step S401: calculating the mean value and the variance of the original image, and assuming that the image P has I lines and J columns, the image mean value formula is as follows:
the image variance formula is:
in the formula, pijRepresenting the pixel values of the image in i rows and j columns;
step S402: converting the pixel value, wherein the conversion formula is as follows:
in the formula, xijRepresenting the pixel values of the image after the conversion of i rows and j columns;
in step S410, the plurality of convolutional neural network layers include a convolutional layer, an excitation layer, a pooling layer, and a partial response normalization layer, wherein,
The maximum pooling operator formula of the pooling layer isWherein y is an element contained in the local acceptance domain;
the local response normalization formula of the local response normalization layer is as follows:
in the formula,is the output of the ith convolution kernel at the (x, y) position,the input of the ith convolution kernel at the position (x, y), N is the number of the convolution kernels, N is the number of the adjacent convolution kernels added with normalization calculation, and parameters k, N, alpha and beta are all hyper-parameters;
the step S420 further includes the steps of:
step S421: averaging the image matrixes of the image training sets to obtain an average matrix of each training set;
step S422: calculating Euclidean distances among the mean value matrixes, wherein the Euclidean distances are represented by the following formula:
where M is the column dimension of the mean matrix, N is the row dimension of the mean matrix, x and y are different mean matrices, xjiAnd yjiJ columns and i rows of elements in the mean value matrix are represented;
step S423: sorting the Euclidean distances among the training sets from small to large;
step S424: merging the training sets corresponding to the smaller Euclidean distance;
in step S440, the back propagation training process specifically includes the following steps:
step S441: initializing weight and bias: randomly assigning a set of smaller non-zero values to the weight w and the bias b;
step S442: inputting a training sample;
step S443: the forward propagation process: calculating the output of the network according to the input of a given convolutional neural network model, finally obtaining the estimated probability, and calculating the cross entropy, wherein the cross entropy formula is as follows:
in the formula, piRepresenting the true probability distribution of each of the spam,estimating probability distribution;
when the cross entropy is less than the desired value, step S444 is performed; otherwise, returning to step S445;
step S444: and (3) a back propagation process: minimizing the cross entropy by using a gradient descent method at a preset learning rate, so that each variable moves towards the direction of continuously reducing the cost, namely the network can adaptively adjust the weight and the bias of each layer, and returning to the step S443; the gradient descent method has the formula:
in the formula, E is an error function, namely cross entropy, eta is a learning rate which is a hyper-parameter, k is training iteration times, and theta is a weight or bias;
step S445: and finishing the node training corresponding to the training set.
6. The intelligent garbage classification system according to claim 1, wherein the implementation of the offline garbage recognition function of the intelligent garbage bin specifically comprises the following steps:
step S510: the cloud server decodes the data which is uploaded by the intelligent classification garbage can and is encoded by base64 into pictures;
step S520: using the pictures and the identification result labels to train a decision tree-based supervised learning garbage identification model of the cloud server;
step S530: packaging the trained garbage recognition model into firmware to be burnt into the microcontroller;
step S540: the microcontroller operates a garbage recognition model to recognize garbage;
in step S540, the microcontroller operates the garbage recognition model to perform garbage recognition, and the method specifically includes the following steps:
step S541: inputting a picture to be identified, traversing the first layer model, and obtaining a target object type with the highest possibility;
step S542: the node where the next layer of the target object class enters the decision tree continuously traverses the leaf model on the node to obtain the target object class with the maximum possibility; repeating the step S542 until all the data in the sub data set belong to the same class, and continuing to execute the step S543;
step S543: and obtaining a final garbage identification result.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202110316322.7A CN113222186B (en) | 2021-03-24 | 2021-03-24 | Intelligent garbage classification system |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202110316322.7A CN113222186B (en) | 2021-03-24 | 2021-03-24 | Intelligent garbage classification system |
Publications (2)
Publication Number | Publication Date |
---|---|
CN113222186A true CN113222186A (en) | 2021-08-06 |
CN113222186B CN113222186B (en) | 2022-02-08 |
Family
ID=77083945
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202110316322.7A Expired - Fee Related CN113222186B (en) | 2021-03-24 | 2021-03-24 | Intelligent garbage classification system |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN113222186B (en) |
Cited By (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN113879724A (en) * | 2021-09-23 | 2022-01-04 | 宁波大学 | Garbage classification system based on crowdsourcing intelligence |
CN114104552A (en) * | 2021-12-21 | 2022-03-01 | 北京石油化工学院 | Resource recovery optimization method, system and storage medium |
CN115182288A (en) * | 2022-06-01 | 2022-10-14 | 广东美房智高机器人有限公司 | Cleaning device |
CN115583448A (en) * | 2022-10-17 | 2023-01-10 | 中国人民解放军海军工程大学 | Intelligent garbage putting and managing integrated platform and method |
Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN109335371A (en) * | 2018-09-30 | 2019-02-15 | 上海檀楠信息科技有限公司 | Intelligent classification dustbin |
CN110210635A (en) * | 2019-06-05 | 2019-09-06 | 周皓冉 | A kind of intelligent classification recovery system that can identify waste |
CN110498152A (en) * | 2019-09-18 | 2019-11-26 | 福州大学 | A kind of intelligent classification dustbin and its method based on AI |
CN110525829A (en) * | 2019-09-18 | 2019-12-03 | 南京天本安全技术有限公司 | A kind of intelligent classification dustbin and intelligent classification system |
US20200082167A1 (en) * | 2018-09-07 | 2020-03-12 | Ben Shalom | System and method for trash-detection and management |
CN111717560A (en) * | 2020-06-14 | 2020-09-29 | 武汉理工大学 | Intelligent classification garbage bin based on computer vision technique |
-
2021
- 2021-03-24 CN CN202110316322.7A patent/CN113222186B/en not_active Expired - Fee Related
Patent Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20200082167A1 (en) * | 2018-09-07 | 2020-03-12 | Ben Shalom | System and method for trash-detection and management |
CN109335371A (en) * | 2018-09-30 | 2019-02-15 | 上海檀楠信息科技有限公司 | Intelligent classification dustbin |
CN110210635A (en) * | 2019-06-05 | 2019-09-06 | 周皓冉 | A kind of intelligent classification recovery system that can identify waste |
CN110498152A (en) * | 2019-09-18 | 2019-11-26 | 福州大学 | A kind of intelligent classification dustbin and its method based on AI |
CN110525829A (en) * | 2019-09-18 | 2019-12-03 | 南京天本安全技术有限公司 | A kind of intelligent classification dustbin and intelligent classification system |
CN111717560A (en) * | 2020-06-14 | 2020-09-29 | 武汉理工大学 | Intelligent classification garbage bin based on computer vision technique |
Cited By (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN113879724A (en) * | 2021-09-23 | 2022-01-04 | 宁波大学 | Garbage classification system based on crowdsourcing intelligence |
CN113879724B (en) * | 2021-09-23 | 2022-08-19 | 宁波大学 | Garbage classification system based on crowdsourcing intelligence |
CN114104552A (en) * | 2021-12-21 | 2022-03-01 | 北京石油化工学院 | Resource recovery optimization method, system and storage medium |
CN115182288A (en) * | 2022-06-01 | 2022-10-14 | 广东美房智高机器人有限公司 | Cleaning device |
CN115583448A (en) * | 2022-10-17 | 2023-01-10 | 中国人民解放军海军工程大学 | Intelligent garbage putting and managing integrated platform and method |
Also Published As
Publication number | Publication date |
---|---|
CN113222186B (en) | 2022-02-08 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN113222186B (en) | Intelligent garbage classification system | |
CN110210635A (en) | A kind of intelligent classification recovery system that can identify waste | |
Maddalena et al. | A self-organizing approach to background subtraction for visual surveillance applications | |
Yang et al. | WasNet: A neural network-based garbage collection management system | |
CN107205016A (en) | The search method of internet of things equipment | |
CN111619992A (en) | Intelligent garbage classification system and method based on machine vision | |
CN108399221A (en) | Indoor electric equipment classifying identification method and system based on big data association analysis | |
CN113052005B (en) | Garbage sorting method and garbage sorting device for household service | |
CN110738131A (en) | Garbage classification management method and device based on deep learning neural network | |
CN111959995A (en) | Garbage classification voice interaction system based on ROS | |
CN109368095A (en) | A kind of anti-overflow dustbin and its control method | |
CN112488162A (en) | Garbage classification method based on active learning | |
CN114118596A (en) | Photovoltaic power generation capacity prediction method and device | |
CN116128254A (en) | Embedded intelligent manufacturing resource configuration method and terminal system based on edge calculation | |
Arunkumar et al. | An internet of things based waste management system using hybrid machine learning technique | |
CN111797787B (en) | Waste image detection and classification system based on Internet of things technology | |
CN212333579U (en) | Garbage classification system based on machine learning | |
Rijah et al. | Smart waste segregation for home environment | |
Elangovan et al. | A deep learning based multiclass segregation of e-waste using hardware software co-simulation | |
Longo et al. | Take the trash out... to the edge. Creating a Smart Waste Bin based on 5G Multi-access Edge Computing | |
CN115512180A (en) | Low-power consumption intelligent monitoring management system | |
CN212100339U (en) | Intelligent classification retrieves device of rubbish | |
CN108629362A (en) | A kind of learning behavior custom discovery quantization system and method towards mobile environment | |
CN113120461A (en) | Garbage classification and identification system and method for smart city | |
Park et al. | Conversion Tools of Spiking Deep Neural Network based on ONNX |
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 | ||
CF01 | Termination of patent right due to non-payment of annual fee | ||
CF01 | Termination of patent right due to non-payment of annual fee |
Granted publication date: 20220208 |