Community garbage classification platform based on ResNet

Through the deep convolutional neural network model and transfer learning technology based on ResNet, a community garbage classification platform was developed, which solved the problems of inefficiency and high classification error rate of traditional garbage classification methods, realized high-precision automatic garbage classification and management, and improved the intelligence level of urban garbage management.

CN119672423APending Publication Date: 2025-03-21ZHEJIANG UNIV OF SCI & TECH
View PDF 0 Cites 2 Cited by

Patent Information

Application Number
CN202411750272.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-02
Publication Date
2025-03-21

AI Technical Summary

Technical Problem

Traditional garbage classification methods are inefficient and have a high classification error rate, which is difficult to meet the needs of modern urban management.

Method used

The deep convolutional neural network model based on ResNet is adopted, combined with transfer learning technology and crawling technology to collect a large amount of domestic waste image data, develop a community garbage classification platform, and realize automatic garbage classification and management.

Benefits of technology

It effectively improves the accuracy of garbage classification, reduces the complexity and error rate of manual operations, improves the convenience and efficiency of the garbage classification process, and monitors the garbage classification situation in real time through data visualization functions, improving management efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119672423A_ABST
    Figure CN119672423A_ABST
Patent Text Reader

Abstract

The invention discloses a community garbage classification platform based on ResNet, and relates to the technical field of household garbage classification, and the platform utilizes a transfer learning technology to finely adjust a ResNet model based on an ImageNet pre-training model so as to realize automatic classification of community garbage. In specific implementation, all layers of the ResNet model are frozen, parameters of Layer4 are unfrozen, Layer3 output features are recombined according to a new garbage classification data set by means of a gradient descent algorithm, and output of Layer4 can better represent advanced features in a garbage classification task. The platform is combined with the mobile terminal and has the functions of garbage classification query, door-to-door recycling reservation and point exchange, and the management terminal can manage users and visual data. The invention aims to significantly improve the garbage classification efficiency and accuracy, simplify the manual operation, and create an intelligent and automatic scheme for community garbage classification management.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of household waste classification, and more specifically, to a community waste classification platform based on ResNet. Background Art

[0002] With the improvement of people's living standards and the acceleration of urbanization, the amount of urban domestic waste is increasing. How to scientifically and efficiently sort waste has become an urgent problem to be solved. The traditional method of waste sorting mainly relies on manual operation, which is inefficient and has a high classification error rate, making it difficult to meet the needs of modern urban management.

[0003] In recent years, with the development of artificial intelligence technology, deep learning has shown excellent performance in the field of image classification. Based on this, the present invention proposes a community garbage classification platform based on the ResNet model to realize automatic classification of garbage and improve the intelligent level of garbage classification management. Summary of the invention

[0004] In view of the shortcomings of the prior art, the purpose of the present invention is to provide a community garbage classification platform based on ResNet.

[0005] To achieve the above object, the present invention provides the following technical solutions:

[0006] A community garbage classification platform based on ResNet includes the following steps:

[0007] Use crawler technology to collect a large amount of household garbage image data, annotate the data according to different garbage categories, and divide them into training sets and verification sets;

[0008] Use the ResNet deep convolutional neural network model, combined with transfer learning technology, to fine-tune the model based on pre-training;

[0009] The user-side applet is developed using the uni-app and uView frameworks, integrating garbage classification query, door-to-door recycling, and points redemption functions;

[0010] Use Vue2 and Element UI framework to develop management web pages, provide data visualization functions, monitor garbage classification in real time, manage platform users and points redemption information;

[0011] Use MySQL database to design the platform's backend data table structure, combine Flask and Axios to develop the backend API interface, and realize efficient data interaction with the front end.

[0012] Preferably, a large amount of household garbage image data is collected by using crawler technology, the data is labeled according to different garbage categories, and a training set and a validation set are divided, including:

[0013] Collect images of 40 common categories of household waste and label them in the “major category-minor category” way;

[0014] Perform image enhancement processing on the collected original domestic garbage images;

[0015] The domestic waste image data are labeled by naming the folders, placing images of the same category in the same folder, and dividing the labeled data set into a training set and a validation set.

[0016] Preferably, the ResNet deep convolutional neural network model is used, combined with transfer learning technology, to fine-tune the model based on pre-training, including:

[0017] The ResNet model is selected as the basic model. Through transfer learning technology, fine-tuning training for garbage classification tasks is performed on the basis of the ImageNet pre-training model. The network structure of ResNet consists of the initial convolution layer, Layer1, Layer2, Layer3, Layer4 and the final classification layer. In this platform, ResNet152 is selected as the pre-training network. Its initial convolution consists of 7*7 convolution with a step size of 2. The number of residual blocks in each group of Layer is 3, 8, 36, and 3 respectively. The residual block adopts a Bottleneck structure. The input is sequentially subjected to 1*1 convolution, 3*3 convolution, and 1*1 convolution, and then the residual is added. Connection f'(x) = f(x) + x, where x is the input of the residual block, f(x) is the output of the residual block after a series of internal transformation operations on the input data x, and the final output f'(x) of the residual block is obtained by adding the output f(x) obtained after the internal transformation operation to the original input x; the first 1*1 convolution in the structure is to reduce the input channel, and the second 1*1 convolution is the recovery channel. This design can reduce the amount of calculation of the model; the design of the residual connection prevents the model from vanishing gradients during gradient descent, thereby training the model to a local optimal solution, while also increasing the possibility of jumps in the training of the model and adaptively adjusting the model depth;

[0018] After testing various strategies, the fine-tuning method of the model was determined as follows: first freeze the parameters of all layers, then unfreeze the parameters of Layer4 in ResNet; use the model pre-trained on ImageNet, based on the new domestic waste classification dataset, update the parameters with the help of the gradient descent algorithm, and recombine the output features of Layer3 in Layer4, so that the output of Layer4 can better reflect the high-level features of the dataset and perform classification accordingly;

[0019] Use the Pytorch framework for model training. Try models of different depths such as ResNet18, ResNet34, ResNet101, ResNet152, and iterate and optimize the model parameters until a better classification effect is achieved.

[0020] Preferably, the user-side applet is developed using the uni-app and uView frameworks, integrating garbage classification query, door-to-door recycling, and points redemption functions, including:

[0021] Develop a user-side mini-program interface that integrates a garbage classification query function. Users can search by text or upload garbage images for classification queries. The platform will call the pre-trained ResNet model to output the garbage classification results and provide recommendations for placement.

[0022] Develop a door-to-door recycling function module. Users can make an appointment for door-to-door recycling service through the mini program, select the recycling time period and estimated weight; the platform will generate a recycling order and dispatch a recycler to provide door-to-door service within the scheduled time;

[0023] Develop a points redemption function module, where users will receive corresponding points after completing garbage sorting or recycling; users can use points to redeem environmentally friendly products or services in the points mall of the mini program;

[0024] It realizes the user information management function, supports user registration, login, information modification and other operations, and synchronizes the user's historical recycling records, points status and other data to the management platform.

[0025] Preferably, the management webpage is developed using Vue2 and Element UI frameworks to provide data visualization functions, monitor garbage classification in real time, and manage platform users and points redemption information, including:

[0026] Develop the management end homepage interface, integrating real-time data visualization function, so that managers can view the overall situation of garbage classification through visualization charts;

[0027] Implement user management module, managers can view, add, delete and modify user information; the platform supports exporting user data;

[0028] Develop shopping mall and exchange management function modules, where managers can view, add, delete and modify product information and set product exchange points; the exchange order module can display residents' exchange application status and historical exchange records;

[0029] Design an environmental information management module, where managers can publish information, activities or notifications related to environmental protection and send important information to the user-side mini program through the push function.

[0030] Preferably, the backend data table structure of the platform is designed using MySQL database, and the backend API interface is developed in combination with Flask and Axios to achieve efficient data interaction with the frontend, including:

[0031] Design and create a MySQL database, and construct data table structures including user information table, garbage classification table, points record table, recycling order table, environmental information table, etc.;

[0032] Optimize database index and query performance, and improve database query efficiency under high concurrency conditions by designing a reasonable index structure and partitioning strategy;

[0033] Develop API interfaces, use the Flask framework to define and implement the platform's backend API, including user registration, login verification, garbage classification query, points management, recycling reservations, environmental protection information push and other functional interfaces;

[0034] The Axios library is used for data interaction between the front-end and the back-end. The front-end calls the back-end API interface through the Axios library to realize dynamic loading and submission of data.

[0035] Compared with the prior art, the present invention has the following beneficial effects:

[0036] 1. The present invention is based on the ResNet deep convolutional neural network model, which can effectively improve the accuracy of garbage classification through transfer learning and fine-tuning technology. Fine-tuning is performed using a pre-trained model so that the classification model can better adapt to the actual classification needs of domestic waste, and show higher accuracy when dealing with the classification tasks of daily life waste. When annotating the data set, it is annotated in the form of "large category-small category", allowing the model to first distinguish according to the small category, and then count and return the classification label according to the large category. The accuracy of such large category classification is definitely higher than that of small category classification, and for some categories not involved in the training set, the model can summarize the rules based on the characteristics of the small categories in the existing large categories, thereby inferring the correct classification.

[0037] 2. In the present invention, by integrating AI technology, users do not need to manually determine the type of garbage, and the platform can automatically identify and classify the garbage. This not only reduces the complexity and error rate of manual operations, but also improves the convenience and efficiency of the garbage classification process. The user-side applet provides a variety of functions such as garbage classification query, door-to-door recycling appointment, and point redemption, which simplifies the operation process of garbage classification. Through the point incentive mechanism, the user's enthusiasm for participation is further enhanced, making garbage classification a more attractive daily activity.

[0038] 3. In the present invention, the management platform can monitor various data of garbage classification in real time through data visualization function, helping managers to make timely decisions. At the same time, the platform provides functional modules such as user management, points management, and environmental protection information release, which comprehensively improves the management efficiency of the garbage classification platform. BRIEF DESCRIPTION OF THE DRAWINGS

[0039] Figure 1 A flowchart of the steps of a community garbage classification platform based on ResNet proposed by the present invention;

[0040] Figure 2 This is a sub-step flow chart of S1 proposed by the present invention;

[0041] Figure 3 This is a sub-step flow chart of S3 proposed by the present invention;

[0042] Figure 4 This is a sub-step flow chart of S4 proposed by the present invention;

[0043] Figure 5 This is a flow chart of the sub-steps of S5 proposed by the present invention. DETAILED DESCRIPTION

[0044] The embodiment further illustrates a community garbage classification platform based on ResNet proposed by the present invention.

[0045] Reference Figure 1 , a community garbage classification platform based on ResNet, including the following steps:

[0046] S1, uses crawler technology to collect a large amount of household garbage image data, annotates the data according to different garbage categories, and divides them into training sets and validation sets;

[0047] S2 uses the ResNet deep convolutional neural network model and combines it with transfer learning technology to fine-tune the model based on pre-training;

[0048] S3, using uni-app and uView framework to develop user-side applet, integrating garbage classification query, door-to-door recycling, and points redemption functions;

[0049] S4, using Vue2 and Element UI framework to develop management web pages, providing data visualization functions, real-time monitoring of garbage classification, management platform users and points redemption information;

[0050] S5 uses MySQL database to design the backend data table structure of the platform, and combines Flask and Axios to develop the backend API interface to achieve efficient data interaction with the front end.

[0051] Reference Figure 2, step S1 is specifically implemented by the following steps:

[0052] S101, collect images of 40 common categories of household waste and label them in the “major category-minor category” way.

[0053] The major categories include recyclables, hazardous waste, kitchen waste, and other waste, specifically:

[0054] Recyclables are renewable resources, referring to uncontaminated waste in domestic waste that is suitable for recycling and reuse; they mainly include five categories: discarded electrical and electronic products, waste paper, waste plastics, waste glass, and waste metals. They are the main task of domestic waste classification at this stage and an important factor affecting waste reduction.

[0055] Hazardous waste refers to substances in domestic waste that cause direct or potential harm to human health or the natural environment. They must be collected, transported, and stored separately, and specially handled safely by professional organizations approved by the environmental protection department. Common hazardous waste includes waste light bulbs, waste paint, pesticides, discarded cosmetics, expired medicines, waste batteries, waste light bulbs, waste mercury thermometers, etc.

[0056] Kitchen waste refers to garbage generated in residents' daily lives and in food processing, catering services, and unit meal supply activities, including discarded vegetable leaves, leftovers, leftover rice, fruit peels, egg shells, tea dregs, bones (chicken bones, fish bones), etc. Its main sources are home kitchens, restaurants, hotels, canteens, markets, and other industries related to food processing.

[0057] Other garbage refers to other domestic garbage except recyclables, hazardous waste and kitchen waste.

[0058] The reason for labeling in the "big category-small category" way is that in the image recognition task, the model can only give classification by capturing visual feature information. The classification rules for domestic waste are relatively complex, and it is very difficult to label domestic waste according to major categories only through visual information. Labeling in the "big category-small category" way allows the model to first distinguish according to minor categories, and then count and return classification labels according to major categories. The accuracy of such large category classification is definitely higher than that of small category classification, and for some categories not involved in the training set, the model can summarize the rules based on the characteristics of small categories in the existing large categories, and thus infer the correct classification.

[0059] S102, performing image enhancement processing on the collected original household garbage image.

[0060] The processing method includes random horizontal flipping, random rotation and normalization processing, specifically:

[0061] After using the graphics library Torchvision in pytorch to read the original domestic garbage image, the function transforms.Resize() is used in turn to adjust the original domestic garbage image to the specified size, and the parameter is the size of the adjusted image; transforms.RandomHorizontalFlip() is used to randomly flip the input image horizontally, and the parameter is the flipping probability; transforms.RandomRotation() is used to randomly rotate the input image, and the parameter is the rotation angle range; transforms.ToTensor() is used to convert the RGB image to the (C, H, W) Tensor format for GPU accelerated computing, where C is the number of channels (the number of channels of RGB images is 3), and H and W are the height and width of the image respectively; transforms.Normalize() is used to implement data normalization processing, and the parameters are the mean and variance of each channel.

[0062] Random flipping and rotation operations make the data set for each round of training slightly different, adding noise to the training set, which can effectively prevent overfitting in model training, that is, avoid the model performing too well in the training set and having poor recognition ability for new samples input in the validation set and daily use, thereby increasing the generalization ability of the model; normalization processing is to standardize the image channel by channel, which can speed up the convergence of the model.

[0063] S103, labeling the domestic waste image data by naming the folders, placing images of the same category in the same folder, and dividing the labeled data set into a training set and a verification set.

[0064] The total number of pictures in the collected data set is 16,665. First, a total of 401 pictures are randomly selected from each category as the test set; then for each classification label category, pictures are randomly selected at a ratio of about 15% and put into the validation set, and the remaining pictures are used as the training set; finally, there are 13,842 training set pictures, 2,422 validation set pictures, and 401 test set pictures, with a ratio of about 0.83:0.15:0.02.

[0065] Step S2 is specifically implemented by the following steps:

[0066] The ResNet model is selected as the basic model. Through transfer learning technology, fine-tuning training for garbage classification tasks is performed on the basis of the ImageNet pre-training model. The network structure of ResNet consists of the initial convolution layer, Layer1, Layer2, Layer3, Layer4 and the final classification layer. In the design of this platform, since the real-time requirement is not high, ResNet152 is selected as the pre-training network. Its initial convolution consists of 7*7 convolution with a step size of 2. The number of residual blocks in each group of Layer is 3, 8, 36, and 3 respectively. The residual block adopts a Bottleneck structure. The input is sequentially processed by 1*1 convolution, 3*3 convolution, and 1*1 A residual connection f'(x)=f(x)+x is added after the convolution, where x is the input of the residual block, f(x) is the output obtained after the residual block performs a series of internal transformation operations on the input data x, and the final output f'(x) of the residual block is obtained by adding the output f(x) obtained after the internal transformation operation to the original input x; the first 1*1 convolution in the structure is to reduce the input channel, and the second 1*1 convolution is to restore the channel. This design can reduce the amount of calculation of the model; the design of the residual connection enables the model to avoid the gradient disappearance during gradient descent, thereby training the model to a local optimal solution. At the same time, it also increases the possibility of jumping in the training of the model and adaptively adjusts the model depth.

[0067] After fine-tuning the model through various strategy tests, the model fine-tuning method was determined as follows: first freeze the parameters of all layers, and then unfreeze the Layer4 parameters in ResNet; use the model pre-trained on ImageNet, based on the new domestic waste classification dataset, update the parameters with the help of the gradient descent algorithm, and recombine the output features of Layer3 in Layer4, so that the Layer4 output can better reflect the high-level features of the dataset and perform classification accordingly.

[0068] Use the Pytorch framework for model training. Try models of different depths such as ResNet18, ResNet34, ResNet101, ResNet152, and iterate and optimize the model parameters until a better classification effect is achieved.

[0069] According to the above iterative optimization of model parameters, the final training parameters are: initial learning rate is 0.001, iteration round is 20, batch size is 32, number of target categories is 40, optimizer is MSGD, the labeled domestic waste image dataset is loaded into the training script, and the trained model parameters are saved as a pth format file using torch.save; in the back-end code of the subsequent garbage classification and recognition function, after using torch.load to load the pre-trained model settings, use net.load_state_dict to load the parameters into the created resnet152 network.

[0070] Reference Figure 3 , step S3 is specifically implemented by the following steps:

[0071] S301, develop a user-side mini-program interface and integrate the garbage classification query function. Users can search by text or upload garbage pictures for classification query; the platform will call the pre-trained ResNet model, output the garbage classification results, and provide disposal suggestions.

[0072] S302, develop a door-to-door recycling function module. Users can make an appointment for door-to-door recycling service through the mini program, select the recycling time period and estimated weight; the platform will generate a recycling order and dispatch a recycler to provide door-to-door service within the appointment time.

[0073] S303, develop a points redemption function module, where users will receive corresponding points as rewards after completing garbage sorting or recycling; users can use points to redeem environmentally friendly products or services in the points mall of the mini program.

[0074] S304 implements the user information management function, supports user registration, login, information modification and other operations, and synchronizes the user's historical recycling records, points and other data to the management platform.

[0075] Specifically, the uniapp framework is used for user-side development. uni-app is a cross-platform application development framework based on Vue.js. Developers can use the same set of codes to build applications that can run on iOS, Android, H5, and various mini-program platforms. During the development process, the WeChat mini-program end is taken as an example, and the WeChat developer tools are used for page debugging; in the mini-program development, uView and uniapp's own components are used as the development component library; on this basis, the front-end design of pages such as the homepage, garbage classification query, door-to-door recycling, and points redemption is completed; in the front-end, uniapp's requestAPI is used to realize data exchange with the back-end Flask framework; by writing the interaction between the Flask backend and the database, the various functional modules of the user end are implemented in turn.

[0076] Reference Figure 4 Step S4 is specifically implemented by the following steps:

[0077] S401, develops the management homepage interface, integrating real-time data visualization function, so that managers can view the overall situation of garbage classification through visual charts.

[0078] The overall situation of garbage classification includes key indicators such as monthly garbage classification statistics and classification ratios of different types of garbage.

[0079] S402, implement the user management module, managers can view, add, delete and modify user information; the platform supports exporting user data.

[0080] The user information includes the user's basic information, points, classification records, etc.

[0081] S403, develop the mall and exchange management function module, where managers can view, add, delete and modify product information and set product exchange points; the exchange order module can display residents' exchange application status and historical exchange records.

[0082] S404, design an environmental information management module, where managers can publish information, activities or notifications related to environmental protection and send important information to the user-side mini program through the push function.

[0083] Specifically, the management web page is developed using Vue2 and Element UI frameworks to provide data visualization functions. Managers can monitor the garbage classification situation in real time through the platform, which is achieved by using ECharts; ECharts is a Javascript-based data visualization chart library that provides intuitive, vivid, interactive, and customizable data visualization charts; on the homepage of the management side, by returning the data in the garbage collection table and performing simple calculations, ECharts is used to generate charts such as monthly garbage quantity and type statistics, and classification ratios of different types of garbage.

[0084] In the development of the management web page, the Axios library is used to communicate with the Flask backend; Axios is a Promise-based HTTP client for browsers and nodejs, which creates XMLHttpRequest from the browser; Axios can implement functions such as sending requests and processing responses, and through communication with Flask, it completes the interaction with the database, including adding, modifying, deleting, and querying; through basic operations on the database, it realizes the design and development of functional management modules such as door-to-door recycling, product exchange, and user information.

[0085] Reference Figure 5 Step S5 is specifically implemented by the following steps:

[0086] S501, design and create a MySQL database, and construct a data table structure including a user information table, a garbage classification table, a points record table, a recycling order table, an environmental information table, etc.

[0087] S502, optimize database index and query performance, and improve the query efficiency of the database under high concurrency by designing a reasonable index structure and partitioning strategy.

[0088] S503, develop API interface, use Flask framework to define and implement the platform's backend API, including user registration, login verification, garbage classification query, points management, recycling appointment, environmental protection information push and other functional interfaces.

[0089] S504, using the Axios library for data interaction between the front-end and the back-end, the front-end calls the back-end API interface through the Axios library to achieve dynamic loading and submission of data.

[0090] Specifically, we designed and created a MySQL database, and constructed a data table structure including user information table, garbage classification table, points record table, recycling order table, environmental information table, etc., to ensure that platform data can be stored and managed safely and stably.

[0091] Develop API interfaces, use the Flask framework to define and implement the platform's back-end API, including user registration, login verification, garbage classification query, points management, recycling appointments, environmental information push and other functional interfaces; ensure that the data interaction between the front and back ends can be completed safely and quickly; use uniapp's own request interface on the user side, and use the Axios library on the management web page to interact with the front and back ends, and realize dynamic loading and submission of data, such as displaying garbage classification query results, processing points redemption requests, updating user information and other operations.

[0092] The above is only a preferred embodiment of the present invention, and the protection scope of the present invention is not limited to the above embodiments. All technical solutions under the concept of the present invention belong to the protection scope of the present invention. It should be pointed out that for ordinary technicians in this technical field, some improvements and modifications without departing from the principle of the present invention should also be regarded as the protection scope of the present invention.

Claims

1. A community garbage classification platform based on ResNet, characterized in that: The following steps are involved: Use crawler technology to collect a large amount of household garbage image data, annotate the data according to different garbage categories, and divide them into training sets and verification sets; Use the ResNet deep convolutional neural network model, combined with transfer learning technology, to fine-tune the model based on pre-training; The user-side applet is developed using the uni-app and uView frameworks, integrating garbage classification query, door-to-door recycling, and points redemption functions; Use Vue2 and Element UI framework to develop management web pages, provide data visualization functions, monitor garbage classification in real time, manage platform users and points redemption information; Use MySQL database to design the platform's backend data table structure, combine Flask and Axios to develop the backend API interface, and realize efficient data interaction with the front end.

2. A community garbage classification platform based on ResNet according to claim 1, characterized in that: We use crawler technology to collect a large amount of household garbage image data, annotate the data according to different garbage categories, and divide the data into training sets and verification sets, including: Collect images of 40 common categories of household waste and label them in the "major category-minor category" way; Perform image enhancement processing on the collected original domestic garbage images; The domestic waste image data are labeled by naming the folders, placing images of the same category in the same folder, and dividing the labeled data set into a training set and a validation set.

3. A community garbage classification platform based on ResNet according to claim 2, characterized in that: Use the ResNet deep convolutional neural network model, combined with transfer learning technology, to fine-tune the model based on pre-training, including: The ResNet model is selected as the basic model. Through transfer learning technology, fine-tuning training for garbage classification tasks is performed on the basis of the ImageNet pre-training model. The network structure of ResNet consists of the initial convolution layer, Layer1, Layer2, Layer3, Layer4 and the final classification layer. In this platform, ResNet152 is selected as the pre-training network. Its initial convolution consists of 7*7 convolution with a step size of 2. The number of residual blocks in each group of Layer is 3, 8, 36, and 3 respectively. The residual block adopts a Bottleneck structure. The input is sequentially subjected to 1*1 convolution, 3*3 convolution, and 1*1 convolution, and then the residual is added. Connection f'(x) = f(x) + x, where x is the input of the residual block, f(x) is the output of the residual block after a series of internal transformation operations on the input data x, and the final output f'(x) of the residual block is obtained by adding the output f(x) obtained after the internal transformation operation to the original input x; the first 1*1 convolution in the structure is to reduce the input channel, and the second 1*1 convolution is the recovery channel. This design can reduce the amount of calculation of the model; the design of the residual connection prevents the model from vanishing gradients during gradient descent, thereby training the model to a local optimal solution, while also increasing the possibility of jumps in the training of the model and adaptively adjusting the model depth; After testing various strategies, the fine-tuning method of the model was determined as follows: first freeze the parameters of all layers, then unfreeze the parameters of Layer4 in ResNet; use the model pre-trained on ImageNet, based on the new domestic waste classification dataset, update the parameters with the help of the gradient descent algorithm, and recombine the output features of Layer3 in Layer4, so that the output of Layer4 can better reflect the high-level features of the dataset and perform classification accordingly; Use the Pytorch framework for model training. Try models of different depths such as ResNet18, ResNet34, ResNet101, ResNet152, and iterate and optimize the model parameters until a better classification effect is achieved.

4. A community garbage classification platform based on ResNet according to claim 3, characterized in that: The user-side applet is developed using the uni-app and uView frameworks, integrating garbage classification query, door-to-door recycling, and points redemption functions, including: Develop a user-side mini-program interface that integrates a garbage classification query function. Users can search by text or upload garbage images for classification queries. The platform will call the pre-trained ResNet model to output the garbage classification results and provide recommendations for placement. Develop a door-to-door recycling function module. Users can make an appointment for door-to-door recycling service through the mini program, select the recycling time period and estimated weight; the platform will generate a recycling order and dispatch a recycler to provide door-to-door service within the scheduled time; Develop a points redemption function module, where users will receive corresponding points after completing garbage sorting or recycling; users can use points to redeem environmentally friendly products or services in the points mall of the mini program; It realizes the user information management function, supports user registration, login, information modification and other operations, and synchronizes the user's historical recycling records, points status and other data to the management platform.

5. A community garbage classification platform based on ResNet according to claim 4, characterized in that: Use Vue2 and Element UI framework to develop management web pages, provide data visualization functions, monitor garbage classification in real time, and manage platform users and points redemption information, including: Develop the management end homepage interface, integrating real-time data visualization function, so that managers can view the overall situation of garbage classification through visualization charts; Implement user management module, managers can view, add, delete and modify user information; the platform supports exporting user data; Develop shopping mall and exchange management function modules, where managers can view, add, delete and modify product information and set product exchange points; the exchange order module can display residents' exchange application status and historical exchange records; Design an environmental information management module, where managers can publish information, activities or notifications related to environmental protection and send important information to the user-side mini program through the push function.

6. A community garbage classification platform based on ResNet according to claim 5, characterized in that: Use MySQL database to design the backend data table structure of the platform, combine Flask and Axios to develop the backend API interface, and realize efficient data interaction with the frontend, including: Design and create a MySQL database, and construct data table structures including user information table, garbage classification table, points record table, recycling order table, environmental information table, etc.; Optimize database index and query performance, and improve database query efficiency under high concurrency conditions by designing a reasonable index structure and partitioning strategy; Develop API interfaces, use the Flask framework to define and implement the platform's backend API, including user registration, login verification, garbage classification query, points management, recycling reservations, environmental protection information push and other functional interfaces; The Axios library is used for data interaction between the front-end and the back-end. The front-end calls the back-end API interface through the Axios library to realize dynamic loading and submission of data.

Citation Information

Cited By

  • Garbage classification multistage verification method based on dynamic confidence threshold and storage medium

    CN120823429A

  • Visual monitoring system and method for broadband network

    CN120825416A