Intelligent feeding control method, device, equipment and medium

By using intelligent feeding control methods and calculating the pig herd's feed intake desire index using target detection models and environmental data, precise feed delivery is achieved, solving the problems of high labor intensity and feed waste in traditional fattening pig farming, and improving the feed intake and breeding efficiency of fattening pigs.

CN117898251BActive Publication Date: 2025-11-21SOUTH CHINA AGRICULTURAL UNIVERSITY +2
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202311847344.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-12-28
Publication Date
2025-11-21
Estimated Expiration
2043-12-28

AI Technical Summary

Technical Problem

In traditional fattening pig farming, the mechanical feeding method, which relies on the experience of the farmers, results in high labor intensity, increased breeding costs, slow daily weight gain of pigs, long time to market, and a lot of feed waste.

Method used

An intelligent feeding control method is adopted. By collecting images of pigs and environmental data, a pre-trained target detection model is used to determine the center point of the pig herd and the location of the feeding vessel, calculate the pig herd's feeding desire index, and accurately control the amount of feed delivered.

Benefits of technology

It reduces the intensity of manual labor, increases the amount of feed consumed by pigs, avoids feed waste, ensures the accuracy and efficiency of feeding, and reduces breeding costs.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117898251B_ABST
    Figure CN117898251B_ABST
Patent Text Reader

Abstract

The application relates to an intelligent feeding control method, device, equipment and medium, which comprises the following steps: collecting pig group image frames of each angle, pig group environment data and historical feeding data in a preset time range; performing target detection on the pig group image frames based on a pre-trained target detection model, determining the minimum circumscribed rectangle of each pig, a feeding device and a waterer in the pig group image frames, and determining the pig group center point, the number of standing pigs, the number of pigs close to the waterer and the number of pigs close to the feeding device according to the minimum circumscribed rectangle of each pig, the feeding device and the waterer; determining the pig group feeding desire index according to the moving distance of the pig group center point, the number of standing pigs, the number of pigs close to the waterer and the number of pigs close to the feeding device; and determining the feed delivery amount of the pig group according to the pig group environment data, the historical feeding data and the pig group feeding desire index, so as to complete the intelligent feeding of the pig group. The application can ensure the accuracy of the feed delivery amount.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of livestock feeding, and in particular to an intelligent feeding control method, a corresponding device, an electronic device and a computer readable storage medium. BACKGROUND

[0002] Pig farming is an important industry in China's agriculture, and is changing from traditional pig farming to modern pig farming. Whether it is breeding mode, regional layout or production method and production capacity, significant changes are taking place.

[0003] In traditional fattening pig feeding, the feeding staff manually controls the mechanical feeding according to experience. The work experience of the feeding staff is required to be high, the labor intensity is large, and the breeding cost is increased to some extent. At the same time, the fattening pig's daily weight gain is slow, the time to market is long, and the feed is wasted.

[0004] In summary, in order to adapt to the existing technology for fattening pig feeding, the feeding staff manually controls the mechanical feeding according to experience. The work experience of the feeding staff is required to be high, the labor intensity is large, and the breeding cost is increased to some extent. At the same time, the fattening pig's daily weight gain is slow, the time to market is long, and the feed is wasted. In view of solving the problem, the applicant makes corresponding exploration. SUMMARY

[0005] The purpose of the present application is to solve the above problems and provide an intelligent feeding control method, a corresponding device, an electronic device and a computer readable storage medium.

[0006] In order to achieve the various purposes of the present application, the present application adopts the following technical solutions:

[0007] An intelligent feeding control method is proposed to adapt to one of the purposes of the present application, comprising:

[0008] In response to an instruction for intelligent feeding of a pig herd, pig herd image frames of each angle, pig herd environment data and historical feeding data within a preset time range are collected in a pig farm;

[0009] Based on a pre-trained target detection model, the pig herd image frames are subjected to target detection to determine the minimum bounding rectangle of each pig, a feeding device and a waterer in the pig herd image frames, and to determine the pig herd center point, the number of standing pigs, the number of pigs close to the waterer and the number of pigs close to the feeding device according to the minimum bounding rectangle of each pig, the feeding device and the waterer;

[0010] The moving track of the pig herd center point within the preset time range is counted, and the moving distance of the pig herd center point is determined according to the moving track of the pig herd center point;

[0011] According to the moving distance of the pig group center point, the number of pigs standing, the number of pigs close to the water dispenser, and the number of pigs close to the food dispenser, a pig group feeding desire index is determined.

[0012] According to the pig group environment data, historical feeding data, and pig group feeding desire index, the feed delivery amount of the pig group is determined to complete intelligent feeding of the pig group.

[0013] Optionally, according to the minimum circumscribed rectangle of each pig, food dispenser, and water dispenser, the steps of determining the pig group center point, the number of pigs standing, the number of pigs close to the water dispenser, and the number of pigs close to the food dispenser include:

[0014] A pre-trained target detection model is called to determine the minimum circumscribed rectangle corresponding to the pig, water dispenser, and food dispenser;

[0015] The intersection-over-union between the minimum circumscribed rectangle corresponding to the pig and the minimum circumscribed rectangle corresponding to the water dispenser and food dispenser is calculated, and the number of pigs close to the water dispenser or food dispenser is determined according to the intersection-over-union.

[0016] Optionally, after the step of determining the pig group feeding desire index according to the moving distance of the pig group center point, the number of pigs standing, the number of pigs close to the water dispenser, and the number of pigs close to the food dispenser, the steps include:

[0017] In response to the feed delivery instruction, the weights corresponding to the pig group growth curve, pig group environment data, and pig group desire index are determined;

[0018] According to the weights corresponding to the pig group growth curve, pig group environment data, and pig group desire index, the feed delivery amount of the pig group is determined to deliver feed to the pig group.

[0019] Optionally, the step of training the target detection model includes:

[0020] A single training sample and its supervision label in the training set are obtained, the training sample is input into the target detection model, and the image feature information of the region corresponding to the coordinates labeled by the supervision label in the pig group image frame of the training sample is extracted;

[0021] The image feature information is classified and mapped to a pre-set classification space corresponding to pigs, water dispensers, and food dispensers, the classification probability corresponding to each classification space is obtained, the pigs, water dispensers, and food dispensers represented by the classification space with the maximum classification probability are determined, and a loss function is used to determine the position information and category of the pigs, water dispensers, and food dispensers labeled by the supervision label.

[0022] The position information of the pig, the waterer and the feeder corresponding to the classification probability maximum classification space representation and the loss value corresponding to the category are calculated, and when each of the loss values reaches a preset threshold value, it indicates that the target detection model has been trained to a convergence state, and the training of the target detection model is completed.

[0023] Optionally, the step of determining the foraging desire index of the pig group according to the moving distance of the pig group center point, the number of pigs standing, the number of pigs close to the waterer and the number of pigs close to the feeder comprises:

[0024] The foraging desire index of the pig group is:

[0025] des=αk 3 +β(l+d) 2 +εg,

[0026] Wherein, des represents the foraging desire index, k represents the number of pigs close to the feeder, l represents the number of standing pigs, d represents the moving distance of the pig group center point, g represents the number of pigs close to the waterer, and α, β and ε are parameters obtained by model training.

[0027] Optionally, the step of determining the feed delivery amount of the pig group according to the pig group environment data, the historical feeding data and the foraging desire index of the pig group comprises:

[0028] The feed delivery amount is:

[0029]

[0030] Wherein, S represents the feed delivery amount, 70≤t≤180, t represents the age of the pig group, represents the pig group environment data.

[0031] Optionally, the basic network architecture of the target detection model is a Yolov5 model.

[0032] The pig group environment data includes one or any multiple of temperature, humidity, light intensity, carbon dioxide, ammonia, oxygen, hydrogen sulfide, formaldehyde, sulfur dioxide, PM2.5 and PM10.

[0033] The historical feeding data includes one or any multiple of pigpen number, entry time, pig age, pig number, foraging amount and water intake.

[0034] Another object of the present application is to provide an intelligent feeding control device, comprising:

[0035] A data acquisition module is arranged to respond to an instruction for intelligent feeding of the pig group, and to acquire pig group image frames of each angle, pig group environment data and historical feeding data within a preset time range in the pig farm.

[0036] The pig group state detection module is configured to perform target detection on the pig group image frame based on a pre-trained target detection model, determine minimum bounding rectangles of each pig, a feeding device and a water device in the pig group image frame, and determine a pig group center point, a standing pig number, and numbers of pigs close to the water device and the feeding device according to the minimum bounding rectangles of each pig, the feeding device and the water device;

[0037] The moving distance determination module is configured to count a moving track of the pig group center point in a preset time range, and determine a moving distance of the pig group center point according to the moving track of the pig group center point.

[0038] The feeding desire determination module is configured to determine a pig group feeding desire index according to the moving distance of the pig group center point, the standing pig number, and the numbers of pigs close to the water device and the feeding device.

[0039] The intelligent feeding module is configured to determine a feed delivery amount of the pig group according to the pig group environment data, historical feeding data and the pig group feeding desire index, so as to complete intelligent feeding of the pig group.

[0040] Another object of the present application is to provide an electronic device comprising a central processing unit and a memory, wherein the central processing unit is configured to invoke a computer program stored in the memory to execute the steps of the intelligent feeding control method.

[0041] Another object of the present application is to provide a computer readable storage medium storing a computer program implemented according to the intelligent feeding control method in the form of computer readable instructions, wherein the computer program is invoked and run by a computer to execute the steps included in the corresponding method.

[0042] Compared with the prior art, the present application is aimed at the mechanical feeding of fattening pigs in the prior art, which is manually controlled by the feeding staff according to experience, requires high working experience of the feeding staff, has high labor intensity, increases the breeding cost to some extent, and has problems such as slow daily weight gain of pigs, long finishing time, and waste of feed.

[0043] Firstly, the present application quantifies the pig group feeding desire according to the activity level of the pig group, determines the pig group feeding desire index, and feeds the pig group according to the pig group feeding desire index, historical feeding data and the pig group growth curve, which can greatly reduce the labor intensity, significantly increase the feeding amount of pigs, and avoid waste of feed.

[0044] Secondly, the application determines index parameters of the pig group that can significantly reflect the foraging desire of the pig group based on the target detection model, such as the number of pigs standing, the number of pigs close to the water dispenser, and the number of pigs close to the food dispenser, etc., which provides good data resources for accurately and quickly determining the foraging desire index of the pig group, so that the intelligent feeding control system can select the appropriate amount of feed to accurately and quickly feed the pig group, greatly saving manpower and resources, ensuring the scientific and healthy growth of the pig group, while avoiding waste of feed, laying a solid theoretical foundation for intelligent farming.

[0045] Further, the intelligent feeding control method of the application does not require human intervention, avoiding overfeeding or underfeeding due to insufficient experience of the breeding personnel, ensuring the accuracy of the amount of feed, effectively improving the feeding efficiency, ensuring high-quality and accurate feeding, effectively avoiding the threat to the healthy growth of the pig group caused by excessive feeding of feed, and effectively avoiding waste of feed, greatly reducing the feeding cost. BRIEF DESCRIPTION OF DRAWINGS

[0046] The above and / or additional aspects and advantages of the application will become apparent and more readily appreciated from the following description of the embodiments, taken in conjunction with the accompanying drawings, in which:

[0047] Figure 1 A module schematic diagram of the intelligent feeding control system of the application;

[0048] Figure 2 A workflow diagram of the intelligent feeding control system in the embodiment of the application;

[0049] Figure 3 A flowchart of the intelligent feeding control method in the embodiment of the application;

[0050] Figure 4 A flowchart of training the target detection model in the embodiment of the application;

[0051] Figure 5 A flowchart of determining the center point of the pig group, the number of pigs standing, and the number of pigs close to the water dispenser and the food dispenser in the embodiment of the application;

[0052] Figure 6 A flowchart of determining the amount of feed for the pig group according to the pig growth curve, the pig environment data, and the corresponding weights of the pig desire index in the embodiment of the application;

[0053] Figure 7 A principle block diagram of the intelligent feeding control device in the embodiment of the application;

[0054] Figure 8 A structure schematic diagram of the computer device in the embodiment of the application. DETAILED DESCRIPTION

[0055] Embodiments of the present application are described below in detail with reference to examples illustrated in the accompanying drawings, in which like or similar elements are denoted throughout by the same or similar reference numerals, and of which the embodiments are not limited, which are merely examples for explaining the present application.

[0056] It is to be understood that the singular forms "a," "an," and "the" include plural referents unless the context clearly dictates otherwise. It is further understood that the terms "comprising," "including," "containing," or "having" and the like, when used herein, mean "including but not limited to." It is still further understood that terms like "connected" or "coupled" as used herein - mean the sharing of a common boundary between elements or the coupling of elements with an intermediate element between them.

[0057] It is to be understood that the singular forms "a," "an," and "the" include plural referents unless the context clearly dictates otherwise. It is further understood that the terms "comprising," "including," "containing," or "having" and the like, when used herein, mean "including but not limited to." It is still further understood that terms like "connected" or "coupled" as used herein - mean the sharing of a common boundary between elements or the coupling of elements with an intermediate element between them.

[0058] Those skilled in the art will appreciate that the term "client", "terminal", "terminal device" as used herein encompasses devices that are solely wireless signal receivers, devices that are wireless signal receivers with no transmit capability, and devices that are both receivers and transmitters capable of bi-directional communication over a bi-directional communication link. Such devices can include cellular or other communication devices with or without a multi-line display, a plurality of push-to-talk buttons, and / or a numeric keypad. Such devices can also include Personal Communications Service (PCS) devices, Personal Digital Assistants (PDAs), cellular telephone / PDA combinations, Internet / Intranet access devices, and / or other devices that are capable of receiving wireless signals. The term "client", "terminal", "terminal device" as used herein can be portable, transportable, installed in a vehicle (aeronautical, maritime, and / or land-based), or adapted to be operated locally and / or in a distributed manner on Earth and / or in any other location in space. The term "client", "terminal", "terminal device" as used herein can also be a communication terminal, an Internet access terminal, a music / video playing terminal, such as a PDA, a Mobile Internet Device (MID), and / or a mobile phone with music / video playing function, a smart television, a set-top box, and / or the like.

[0059] The term "server", "client", "service node", and the like as used herein refers to hardware that has the equivalent capability of a personal computer, and is essentially an electronic device with a central processing unit (including an arithmetic unit and a controller), a memory, an input device, and an output device, and the like necessary components disclosed by the Von Neumann principle. A computer program is stored in the memory, the central processing unit calls the program stored in the external memory into the memory to run, executes the instructions in the program, and interacts with the input and output devices, thereby completing a specific function.

[0060] It should be noted that the concept of "server" in the present application can also be extended to the case of a server cluster. According to the principle of network deployment understood by those skilled in the art, the servers should be logically divided, and in physical space, these servers can be independent of each other but can be called through an interface, or can be integrated into a physical computer or a computer cluster. Those skilled in the art should understand this variation and should not be restricted by the implementation of the network deployment of the present application.

[0061] One or more technical features of the present application, unless explicitly specified, can be deployed on a server and accessed by a client remotely calling an online service interface provided by the server, or can be directly deployed and run on a client to implement access.

[0062] The neural network model referred to or possibly referred to in the present application, unless explicitly specified, can be deployed on a remote server and remotely called by a client, or can be deployed on a client with sufficient device capability for direct calling. In some embodiments, when it runs on a client, its corresponding intelligence can be obtained through transfer learning to reduce the requirement for client hardware running resources and avoid excessive occupation of client hardware running resources.

[0063] The various data involved in the present application, unless explicitly specified, can be remotely stored on a server or stored on a local terminal device, as long as it is suitable for being called by the technical solutions of the present application.

[0064] Those skilled in the art should know that the various methods of the present application, although based on the same concept and described to present commonality among them, are independently executable unless otherwise specified. Similarly, for each embodiment disclosed in the present application, it is based on the same inventive concept, and therefore, for the same conceptually expressed concepts, and although the concepts are expressed differently, they should be understood as equivalent.

[0065] Unless it is explicitly stated that the various embodiments disclosed in the present application are mutually exclusive, the technical features involved in each embodiment can be combined flexibly to construct new embodiments, as long as such combination does not deviate from the spirit of the present application and can meet the needs of the prior art or solve some deficiencies in the prior art. For this variation, those skilled in the art should know.

[0066] In typical embodiments of the present application, the intelligent feeding control can be based on Figure 1 The intelligent feeding control system shown in the figure can be implemented, please refer to Figure 1 and Figure 2 The hardware basis required for the implementation of the related technical solutions of the present application can be implemented according toFigure 1 The intelligent feeding control system in the embodiment includes a data acquisition module, a discharging control module, a central controller, and an Internet of Things cloud platform.

[0067] The data acquisition module includes an image acquisition module, an environment acquisition module, and a feeding amount acquisition module. The environment acquisition module can collect environmental data such as temperature, humidity, light intensity, carbon dioxide, ammonia, oxygen, hydrogen sulfide, formaldehyde, sulfur dioxide, PM2.5, and PM10. The feeding amount acquisition module is integrated in the intelligent porridge machine and is used to count the discharging amount. The image acquisition module is used to acquire real-time pig group images.

[0068] Further, the image data, the environmental data, and the feeding data can be sent to the central controller through CAN communication. The central controller encodes the data through a custom TCP transmission protocol, marks 0, 1, and 2 in the data frame flag bits of the image data, the environmental data, and the feeding data respectively to distinguish the data types. The central controller establishes a TCP link with the cloud platform through a socket and transmits the encoded data to the Internet of Things platform. The feeding data includes the pigpen number, the entry time, the pig age, the number of pigs, the feed intake, and the water intake.

[0069] Further, the discharging control module includes a feeding execution device and a feeding controller. The feeding controller is electrically connected with the central controller. The central controller can issue a feeding instruction to the feeding controller. The feeding controller controls the feeding execution device to discharge. The discharging control module is integrated in the intelligent porridge machine and is used to control discharging.

[0070] Further, the central controller can be a 12-inch touch screen all-in-one machine. The central controller can display pig group information including the device number, the pen number, the stall number, the device state, the entry time, the pig group age, and the feed intake. The central controller can display environmental information including the temperature and humidity, carbon dioxide, ammonia, and sulfur dioxide. The central controller transmits data to the cloud through 4G communication technology.

[0071] Further, the Internet of Things platform includes a data processing module, a data calculation module, a data decision module, and a data storage module.

[0072] Further, the data processing module is used to decode the data sent by the central controller and judge the data types through the flag bits. The image data is transferred to the data calculation module, and the feeding data and the environmental data are transferred to the data storage module for storage.

[0073] Further, the data calculation module performs image recognition, calculates the moving distance of the pig group center, counts the number of standing pigs, calculates the number of pigs close to the feeding device and the number of pigs close to the water device, quantifies the feeding desire of the pig group, and obtains the pig group desire index.

[0074] Further, the data decision module transmits the calculated feeding amount to the central controller through a TCP protocol, and the central controller controls the feeding controller to complete the feeding of the feed.

[0075] Further, the cloud Internet of Things platform transmits the decision result to the central controller through a TCP protocol, and the central controller controls the feeding module to complete the precise feeding of the feed.

[0076] Based on the above exemplary scenarios, please refer to Figure 3 In an embodiment of the intelligent feeding control method of the present application, the method comprises:

[0077] Step S10, in response to an instruction for intelligent feeding of a pig group, collect pig group image frames of each angle, pig group environment data and historical feeding data in a preset time range in a pig farm;

[0078] The intelligent feeding control system can collect pig group image frames of each angle, pig group environment data and historical feeding data in a preset time range in a pig farm in response to an instruction for intelligent feeding of a pig group. The preset time range can be 30 minutes, 60 minutes or 90 minutes, etc. A person skilled in the art can determine the corresponding time range as needed according to the actual situation, which is not limited here.

[0079] Pictures that need to be fed intelligently by the technical solution of the present application can be regarded as the image frames of the present application. The type and source of the image frames are determined according to the actual application scenario. For example, in the application scenario of image beautification processing, the image frame can be a static picture specified by the user; in the scenario of intelligent feeding of a pig group, the pig group image frame can be a pig group image frame collected by the image collection module in the intelligent feeding control system; in the scenario of intelligent feeding of a pig group from a preview video stream obtained by a camera unit of the intelligent feeding control system, the image frame can be an image frame in the preview video stream. Similarly, the image frame can be determined as needed according to the specific application scenario.

[0080] In some embodiments, the pig group environment data includes one or any multiple of temperature, humidity, light intensity, carbon dioxide, ammonia, oxygen, hydrogen sulfide, formaldehyde, sulfur dioxide, PM2.5 and PM10; and the historical feeding data includes one or any multiple of pigpen number, entry time, pig age, pig number, feeding amount and water intake.

[0081] Step S20, performing target detection on the pig group image frame based on the pre-trained target detection model, determining the minimum bounding rectangle of each pig, the feeder and the waterer in the pig group image frame, and determining the pig group center point, the number of standing pigs, the number of pigs close to the waterer and the number of pigs close to the feeder according to the minimum bounding rectangle of each pig, the feeder and the waterer;

[0082] Since the Yolov5 model has the advantages of high detection accuracy and fast recognition speed, the basic network architecture of the target detection model of the present application is the Yolov5 model. The pre-trained target detection model is used to perform target detection on the pig group image frame, determine the minimum bounding rectangle of each pig, the feeder and the waterer in the pig group image frame, and determine the pig group center point, the number of standing pigs, the number of pigs close to the waterer and the number of pigs close to the feeder according to the minimum bounding rectangle of each pig, the feeder and the waterer.

[0083] Please refer to Figure 4 , the steps of training the target detection model, comprising:

[0084] Step S100, obtaining a single training sample and its supervision label in the training set, inputting the training sample into the target detection model, and extracting image feature information of a region corresponding to coordinates labeled by the supervision label in a pig group image frame of the training sample;

[0085] Step S200, classifying and mapping the image feature information to a pre-set classification space representing pigs, waterers and feeders, obtaining a classification probability corresponding to each classification space, determining a pig, a waterer and a feeder represented by a classification space with the maximum classification probability, and using a loss function based on the position information and the category of the pig, the waterer and the feeder labeled by the supervision label.

[0086] Step S300, calculating the position information and the category of the pig, the waterer and the feeder represented by the classification space with the maximum classification probability, and when each of the loss values reaches a pre-set threshold value, it indicates that the target detection model has been trained to a converged state, and the training of the target detection model is completed.

[0087] Specifically, pig group image frames in which pigs, water dispensers and feeders exist are pre-acquired as training samples, each training sample is labeled with a supervision label, the position information of pigs, water dispensers and feeders in the pig group image frame of the training sample and the categories corresponding to the pigs, water dispensers and feeders are labeled, and on the basis of labeling each training sample, a training set is constructed by mapping each training sample and its supervision label, a single training sample and its supervision label in the training set are obtained, the training sample is input into a target detection model, and image feature information of a region corresponding to coordinates labeled by the supervision label in the pig group image frame of the training sample is extracted; the image feature information is classified and mapped to a preset classification space representing pigs, water dispensers and feeders, a classification probability corresponding to each classification space is obtained, pigs, water dispensers and feeders represented by the classification space with the maximum classification probability are determined, a loss function is used to determine the position information and categories of pigs, water dispensers and feeders labeled by the supervision label, the loss value corresponding to the position information and categories of pigs, water dispensers and feeders represented by the classification space with the maximum classification probability is calculated, when each loss value reaches a preset threshold, it indicates that the target detection model has been trained to a convergent state, so that the model training can be terminated, otherwise, it indicates that the model has not converged, the model can be updated according to each loss value, the weight parameters of each link of the model are usually corrected through back propagation to make the model further approach convergence, then the next training sample in the training set is called to implement iterative training on the model until the model is trained to a convergent state. It is not difficult to understand that the target detection model trained to a convergent state can detect the categories and corresponding bounding box positions of pigs, water dispensers and feeders in the pig group image frame.

[0088] In some embodiments, referring to Figure 5 , the steps of determining the pig group center point, the number of pigs standing, the number of pigs close to the water dispenser and the number of pigs close to the feeder according to the minimum bounding rectangles of each pig, feeder and water dispenser, include:

[0089] Step S201, a pre-trained target detection model is called to determine the minimum bounding rectangles corresponding to the pigs, water dispensers and feeders;

[0090] Step S203, the intersection over union between the minimum bounding rectangle corresponding to the pigs and the minimum bounding rectangles corresponding to the water dispensers and feeders is calculated, and the number of pigs close to the water dispenser or the feeder is determined according to the intersection over union.

[0091] When the target detection model is completed pre-training, the intelligent feeding control system can call the pre-trained target detection model to determine the minimum bounding rectangle corresponding to the pig, waterer and feeder; calculate the intersection-over-union between the minimum bounding rectangle corresponding to the pig and the minimum bounding rectangle corresponding to the waterer and feeder, and determine the number of pigs close to the waterer or the feeder according to the intersection-over-union.

[0092] Specifically, based on the pre-trained target detection model, the minimum bounding rectangle corresponding to the pig, waterer and feeder is determined, the intersection-over-union between the minimum bounding rectangle of the pig and the minimum bounding rectangle of the waterer and feeder is calculated, and whether the pig is close to the waterer or the feeder is determined according to the intersection-over-union. The calculation formula is as follows:

[0093] The number of pigs close to the feeder k calculation formula:

[0094]

[0095] Wherein, k represents the number of pigs close to the feeder, I f represents the minimum bounding rectangle area of the feeder, I represents the minimum bounding rectangle size of the current pig;

[0096] The number of pigs close to the waterer g calculation formula:

[0097]

[0098] Wherein, g represents the number of pigs close to the waterer, I w represents the minimum bounding rectangle area of the waterer, I represents the minimum bounding rectangle size of the current pig.

[0099] According to the above calculation formula, the intersection-over-union between the minimum bounding rectangle corresponding to the pig and the minimum bounding rectangle corresponding to the waterer and feeder is calculated, and the number of pigs close to the waterer or the feeder can be calculated according to the intersection-over-union.

[0100] Step S30, the moving track of the pig group center point in the preset time range is counted, and the moving distance of the pig group center point is determined according to the moving track of the pig group center point;

[0101] Specifically, based on the pre-trained target detection model, the minimum bounding rectangle corresponding to each pig in the pig group image frame is identified, the center point position information (x, y) is obtained according to the minimum bounding rectangle, and then the pig group center point is calculated. The formula is as follows:

[0102]

[0103] Wherein, n is the number of pig groups, and μ is the center point.

[0104] The moving track of the pig group center point in the preset time range is counted, and the moving distance of the pig group center point is calculated.

[0105]

[0106] wherein T represents a time period, k(Dis end , Dis start ) is represented as follows:

[0107]

[0108] wherein r is a parameter obtained by training, and Dis

[0109] Step S40, determining the pig group feeding desire index according to the moving distance of the pig group center point, the number of pigs standing, and the number of pigs close to the waterer and the feeder.

[0110] After the moving distance of the pig group center point is determined according to the moving track of the pig group center point, the pig group feeding desire index is determined according to the moving distance of the pig group center point, the number of pigs standing, and the number of pigs close to the waterer and the feeder, and the pig group feeding desire is quantified by the pig group feeding desire index.

[0111] The step of determining the pig group feeding desire index according to the moving distance of the pig group center point, the number of pigs standing, and the number of pigs close to the waterer and the feeder includes:

[0112] The pig group feeding desire index is:

[0113] des=αk 3 +β(l+d) 2 +εg,

[0114] wherein des represents the feeding desire index, k represents the number of pigs close to the feeder, l represents the number of pigs standing, d represents the moving distance of the pig group center point, g represents the number of pigs close to the waterer, and a, β and ε are parameters obtained by training.

[0115] Specifically, the data calculation module in the intelligent feeding control system quantifies the pig group feeding desire according to the moving distance of the pig group center point, the number of pigs standing, and the number of pigs close to the waterer and the feeder in a period of time, and the formula is represented as follows:

[0116] des=αk 3 +β(l+d)2 + εg,

[0117] wherein, des represents the feeding desire index, k represents the number of heads close to the feeder, l represents the number of standing heads, d represents the moving distance of the center point of the pig group, g represents the number of heads close to the waterer, and a, β and ε are parameters obtained by model training.

[0118] In some embodiments, referring to Figure 6 , the step of determining the feeding desire index of the pig group according to the moving distance of the center point of the pig group, the number of standing pigs, the number of pigs close to the waterer, and the number of pigs close to the feeder includes:

[0119] Step S401, in response to the feeding instruction, determining the weight corresponding to the pig group growth curve, pig group environment data and pig group desire index;

[0120] Step S403, determining the feeding amount of the pig group according to the weight corresponding to the pig group growth curve, pig group environment data and pig group desire index to feed the pig group.

[0121] In order to more scientifically and healthily feed the pig group, ensure the scientific and healthy growth of the pig group, and at the same time, avoid the waste and excessive feeding of feed, the intelligent feeding control system can respond to the feeding instruction, combine the pig group growth curve, pig group environment data and pig group desire index, determine the weight corresponding to the pig group growth curve, pig group environment data and pig group desire index; determine the feeding amount of the pig group according to the weight corresponding to the pig group growth curve, pig group environment data and pig group desire index to feed the pig group.

[0122] Step S50, determining the feeding amount of the pig group according to the pig group environment data, historical feeding data and pig group feeding desire index to complete the intelligent feeding of the pig group.

[0123] After determining the pig group environment data, historical feeding data and pig group feeding desire index, the feeding amount of the pig group is determined according to the pig group environment data, historical feeding data and pig group feeding desire index to complete the intelligent feeding of the pig group.

[0124] The step of determining the feeding amount of the pig group according to the pig group environment data, historical feeding data and pig group feeding desire index includes:

[0125] The feeding amount is:

[0126]

[0127] wherein, S represents the feeding amount, 70≤t≤180, t represents the age of the pig group, represent pig group environment data, e1, etc. represent temperature, humidity, light intensity, carbon dioxide, ammonia, oxygen, hydrogen sulfide, formaldehyde, sulfur dioxide, PM2.5 and PM10, etc. environment data.

[0128] From the above embodiments, compared with the prior art, the present application is aimed at the mechanical feeding of fattening pigs in the prior art, which is manually controlled by the feeding staff according to experience, and has high requirements for the working experience of the feeding staff, high labor intensity, and increases the breeding cost to some extent, and the piglets have slow daily weight gain, long finishing time, and waste a lot of feed. The present application includes but is not limited to the following beneficial effects:

[0129] Firstly, the present application quantifies the pig group feeding desire according to the activity level of the pig group, determines the pig group feeding desire index, and feeds the pig group according to the pig group feeding desire index, historical feeding data and pig group growth curve, which can greatly reduce the labor intensity, significantly improve the feeding amount of the piglets, and avoid waste of feed;

[0130] Secondly, the present application determines the index parameters that can significantly reflect the pig group feeding desire based on the target detection model, such as the number of pigs standing, the number of pigs close to the water dispenser and the number of pigs close to the food dispenser, etc. Index parameters provide good data resources for accurately and quickly determining the pig group feeding desire index, so that the intelligent feeding control system can select the appropriate feed amount to accurately and quickly feed the pig group, greatly saving manpower and material resources, ensuring the scientific and healthy growth of the pig group, and avoiding waste of feed, laying a solid theoretical foundation for intelligent breeding;

[0131] Further, the intelligent feeding control method of the present application does not require human participation, avoids overfeeding or underfeeding due to insufficient experience of the breeding personnel, ensures the accuracy of the feeding amount, effectively improves the feeding efficiency, ensures high-quality and accurate feeding, effectively avoids the threat to the healthy growth of the pig group caused by excessive feeding of feed, and effectively avoids waste of feed, greatly reducing the feeding cost.

[0132] Please refer to Figure 7, provided by one of the purposes of the application, an intelligent feeding control device, comprising a data acquisition module 1100, a pig group state detection module 1200, a moving distance determination module 1300, a feeding desire determination module 1400 and an intelligent feeding module 1500. Wherein, the data acquisition module 1100 is configured to collect pig group image frames of each angle, pig group environment data and historical feeding data in a preset time range in the pig farm in response to an instruction of intelligent feeding of the pig group; the pig group state detection module 1200 is configured to perform target detection on the pig group image frames based on a pre-trained target detection model, determine the minimum circumscribed rectangle of each pig, a feeding device and a water device in the pig group image frames, and determine the pig group center point, the number of standing pigs, the number of pigs close to the water device and the number of pigs close to the feeding device according to the minimum circumscribed rectangle of each pig, the feeding device and the water device; the moving distance determination module 1300 is configured to count the moving track of the pig group center point in the preset time range, and determine the moving distance of the pig group center point according to the moving track of the pig group center point; the feeding desire determination module 1400 is configured to determine the pig group feeding desire index according to the moving distance of the pig group center point, the number of standing pigs, the number of pigs close to the water device and the number of pigs close to the feeding device; and the intelligent feeding module 1500 is configured to determine the feed delivery amount of the pig group according to the pig group environment data, the historical feeding data and the pig group feeding desire index, so as to complete the intelligent feeding of the pig group.

[0133] On the basis of any embodiment of the present application, please refer to Figure 8 Another embodiment of the present application further provides an electronic device, which can be realized by a computer device, as shown in Figure 8 , a schematic diagram of the internal structure of the computer device. The computer device comprises a processor, a computer readable storage medium, a memory and a network interface connected through a system bus. Wherein, the computer readable storage medium of the computer device stores an operating system, a database and computer readable instructions, the database can store a control information sequence, and the computer readable instructions can make the processor realize an intelligent feeding control method when executed by the processor. The processor of the computer device is used to provide computing and control capability to support the operation of the whole computer device. The memory of the computer device can store computer readable instructions, which can make the processor execute the intelligent feeding control method of the present application when executed by the processor. The network interface of the computer device is used to connect and communicate with the terminal. Those skilled in the art can understand that Figure 8 The structure shown in the figure is only a block diagram of part of the structure related to the scheme of the present application, and does not constitute a limitation on the computer device to which the scheme of the present application is applied. The specific computer device can include more or less components than those shown in the figure, or combine certain components, or have different component arrangement.

[0134] The processor in this embodiment is configured to execute the specific functions of each module and sub-module in the system, and the memory stores the program codes and various data required for executing the above modules or sub-modules. The network interface is configured to transmit data between the user terminal and the server. The memory in this embodiment stores the program codes and data required for executing all modules / sub-modules in the intelligent feeding control device of the present application, and the server can call the program codes and data of the server to execute the functions of all sub-modules. Figure 7 The processor in this embodiment is configured to execute the specific functions of each module and sub-module in the system, and the memory stores the program codes and various data required for executing the above modules or sub-modules. The network interface is configured to transmit data between the user terminal and the server. The memory in this embodiment stores the program codes and data required for executing all modules / sub-modules in the intelligent feeding control device of the present application, and the server can call the program codes and data of the server to execute the functions of all sub-modules.

[0135] The present application also provides a storage medium storing computer readable instructions, which, when executed by one or more processors, cause the one or more processors to perform the steps of the intelligent feeding control method according to any of the embodiments of the present application.

[0136] The present application also provides a computer program product comprising computer programs / instructions, which, when executed by one or more processors, implement the steps of the intelligent feeding control method according to any of the embodiments of the present application.

[0137] It is understood by those skilled in the art that all or part of the processes in the above-mentioned embodiments of the present application can be completed by a computer program instructing related hardware, which can be stored in a computer readable storage medium. The program, when executed, can include the processes of the above-mentioned embodiments of the method. The storage medium can be a computer readable storage medium such as a magnetic disc, an optical disc, a read-only memory (ROM), or a random access memory (RAM).

[0138] The above only describes some embodiments of the present application. It should be noted that those skilled in the art can make some improvements and refinements without departing from the principles of the present application, and these improvements and refinements should also be considered within the scope of protection of the present application.

[0139] In summary, the intelligent feeding control method of the present application does not require human intervention, avoids overfeeding or underfeeding due to lack of experience of the breeding personnel, ensures the accuracy of the feeding amount, effectively improves the feeding efficiency, ensures high-quality and precise feeding, effectively avoids the threat to the healthy growth of the pig herd caused by fermentation and deterioration of the feed due to overfeeding, effectively avoids waste of feed, and greatly reduces the feeding cost.

Claims

1. An intelligent feeding control method, characterized in that, include: In response to instructions for intelligent feeding of pigs, the system collects images of pigs from various angles within a preset time range, along with pig environment data and historical feeding data. The pre-trained target detection model is used to detect targets in the pig herd image frames to determine the minimum bounding rectangle of each pig, feeder, and waterer in the pig herd image frames. Based on the minimum bounding rectangle of each pig, feeder, and waterer, the pig herd center point, the number of standing pigs, the number of pigs near the waterer, and the number of pigs near the feeder are determined. The movement trajectory of the pig herd center point within a preset time range is statistically analyzed, and the movement distance of the pig herd center point is determined based on the movement trajectory of the pig herd center point. The herd feeding desire index is determined based on the moving distance of the pig herd center point, the number of pigs standing, the number of pigs near the waterer, and the corresponding number of pigs near the fooder. The amount of feed to be given to the pig herd is determined based on the pig herd environmental data, historical feeding data, and pig herd feed desire index, so as to complete the intelligent feeding of the pig herd.

2. The intelligent feeding control method according to claim 1, characterized in that, The steps for determining the pig herd center point, the number of standing pigs, and the corresponding number of pigs near the waterers and feeders based on the minimum bounding rectangle of each pig, feeder, and waterer include: Call the pre-trained target detection model to determine the minimum bounding rectangle corresponding to the pig, waterer, and feeder; Calculate the intersection-union ratio (IUGR) between the minimum bounding rectangle corresponding to the pig and the minimum bounding rectangle corresponding to the waterer and feeder, and determine the number of pigs near the waterer or feeder based on the IUGR.

3. The intelligent feeding control method according to claim 1, characterized in that, After determining the pig herd feeding desire index based on the movement distance of the pig herd center point, the number of pigs standing, the number of pigs near the waterer, and the corresponding number of pigs near the feeder, the following steps are included: In response to feed delivery instructions, determine the corresponding weights of pig growth curves, pig environmental data, and pig desire index; The feed input amount for the pig herd is determined based on the weights corresponding to the pig herd growth curve, pig herd environmental data, and pig herd desire index, so as to carry out feed input for the pig herd.

4. The intelligent feeding control method according to claim 1, characterized in that, The steps for training an object detection model include: Obtain a single training sample and its supervision label from the training set, input the training sample into the target detection model, and extract the image feature information of the region corresponding to the coordinates marked by the supervision label in the pig herd image frame of the training sample; The image feature information is classified and mapped to a preset classification space that represents pigs, waterers, and feeders. The classification probability corresponding to each classification space is obtained. The pigs, waterers, and feeders represented by the classification space with the highest classification probability are determined. A loss function is used based on the location information and category of the pigs, waterers, and feeders labeled by the supervision label. Calculate the location information of the pig, waterer, and food container represented by the classification space with the highest classification probability, as well as the corresponding loss value of the category. When each of the loss values ​​reaches a preset threshold, it indicates that the target detection model has been trained to a convergent state, and the training of the target detection model is completed.

5. The intelligent feeding control method according to claim 1, characterized in that, The steps for determining the feed intake index of the pig herd based on the movement distance of the pig herd's center point, the number of pigs standing, the number of pigs near the waterer, and the corresponding number of pigs near the fooder include: The feed intake index of the pig herd is: , Where des represents the feeding desire index, k represents the number of pigs near the feeder, l represents the number of pigs standing, d represents the distance the pigs move from the center point of the herd, g represents the number of pigs near the waterer, and α, β and ε are parameters obtained from model training.

6. The intelligent feeding control method according to claim 5, characterized in that, The steps for determining the feed input for the pig herd based on the pig herd environmental data, historical feeding data, and the pig herd feed intake index include: The feed dosage is: , Where S represents the amount of feed administered. 70≤t≤180, where t represents the age of the pig herd in days. This represents environmental data for pig herds.

7. The intelligent feeding control method according to any one of claims 1 to 6, characterized in that, The basic network architecture of the target detection model is the Yolov5 model; The environmental data for the pig herd includes one or more of the following: temperature, humidity, light intensity, carbon dioxide, ammonia, oxygen, hydrogen sulfide, formaldehyde, sulfur dioxide, PM2.5, and PM10. The historical feeding data includes one or more of the following: pen number, entry time, pig age, number of pigs, feed intake, and water intake.

8. An intelligent feeding control device, characterized in that, include: The data acquisition module is configured to respond to instructions for intelligent feeding of the pig herd by collecting images of the pig herd from various angles, pig environment data, and historical feeding data within a preset time range in the pig farm. The pig herd status detection module is configured to perform target detection on the pig herd image frame based on a pre-trained target detection model, determine the minimum bounding rectangle of each pig, feeder, and waterer in the pig herd image frame, and determine the pig herd center point, the number of standing pigs, the number of pigs near the waterer, and the number of pigs near the feeder based on the minimum bounding rectangle of each pig, feeder, and waterer. The movement distance determination module is configured to statistically analyze the movement trajectory of the pig herd center point within a preset time range and determine the movement distance of the pig herd center point based on the movement trajectory of the pig herd center point. The feeding desire determination module is set to determine the feeding desire index of the pig herd based on the moving distance of the pig herd center point, the number of pigs standing, the number of pigs near the waterer and the corresponding number of pigs near the fooder. The intelligent feeding module is configured to determine the amount of feed to be given to the pig herd based on the pig herd environmental data, historical feeding data, and the pig herd's feed intake index, so as to complete the intelligent feeding of the pig herd.

9. An electronic device comprising a central processing unit and a memory, characterized in that, The central processing unit is used to invoke and run a computer program stored in the memory to perform the steps of the method as described in any one of claims 1 to 7.

10. A computer-readable storage medium, characterized in that, It stores, in the form of computer-readable instructions, a computer program implemented according to any one of claims 1 to 7, which, when invoked by a computer, executes the steps included in the corresponding method.

Citation Information

Patent Citations

  • Method, system and device for quantifying fish school feeding behavior, and storage medium

    CN111528143A

  • TMR intelligent feeding system and feeding method based on 5G network

    CN111955365A