Corn feed aflatoxin risk early warning traceability method and system
By constructing a source quality-driven dynamic gated spatiotemporal graph neural network model with a composite graph structure, and combining mold growth dynamics and sensor data, the problem of fragmented mechanistic data and neglect of spatial topology in the risk warning of aflatoxin in corn storage was solved. This enabled adaptive risk prediction and responsibility quantification for the corn storage environment, providing precise management decision support.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- GUANGZHOU HONGGUANG LIVESTOCK & POULTRY EQUIP CO LTD
- Filing Date
- 2026-04-15
- Publication Date
- 2026-07-10
AI Technical Summary
Existing technologies for aflatoxin risk warning during corn storage suffer from problems such as fragmented mechanistic data, neglect of spatial topology, and insufficient source explanation, resulting in insufficient model generalization ability and difficulty in ensuring physical consistency, thus failing to meet the requirements of quantitative attribution and legal evidence.
By collecting environmental parameters through sensor networks and combining mold growth kinetics models and graph embedding networks, a source quality-driven dynamic gated spatiotemporal graph neural network model with a composite graph structure is constructed to achieve accurate early warning and source tracing of aflatoxin risk in corn feed. The responsibility ratio is quantified using a spatiotemporal integral gradient attribution method with enhanced rate of change, and the intervention plan is optimized through digital twin simulation.
It enables adaptive risk evolution pattern prediction for corn storage environment, provides early warning 5 to 7 days in advance, improves the model's F1-score and recall rate in extreme scenarios, quantifies the responsibility ratio, and provides precise intervention solutions and management decision support.
Smart Images

Figure CN122367162A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of food quality and safety technology, and in particular to a method and system for early warning and traceability of aflatoxin risk in corn feed. Background Technology
[0002] Aflatoxins are secondary metabolites produced by Aspergillus flavus and Aspergillus parasiticus. Aflatoxin B1 is the most toxic and is classified as a Group 1 carcinogen. Corn, as an important food crop and feed ingredient, occupies a significant position among crops at high risk of aflatoxin contamination. Statistics show that post-harvest loss rates for corn are approximately 8%, with mold damage being the dominant factor, resulting in substantial economic losses.
[0003] Existing aflatoxin risk warning technologies are mostly based on physical mechanism mold growth models. Although they have clear biological interpretability, their models have numerous parameters, strict assumptions, and are difficult to adapt to complex and ever-changing storage conditions. At the same time, while purely data-driven machine learning methods can learn statistical patterns from historical data, they lack explicit embedding of specific aflatoxin contamination mechanisms, resulting in insufficient model generalization ability and difficulty in ensuring physical consistency.
[0004] Aflatoxin contamination in storage environments is not an isolated event. Mold spores spread between warehouses via airflow, creating spatial correlations and cascading amplification effects of risk. However, current technologies generally treat each warehouse as an independent predictive unit, failing to incorporate ventilation network topology, airflow organization patterns, and spore diffusion physics into a unified modeling framework.
[0005] The black-box nature of deep learning models has become a recognized pain point in the industry. Existing technologies mostly provide explanations of relative importance or qualitative correlations, lacking numerical values of contribution with clear physical dimensions, and thus failing to meet the stringent requirements of quantitative attribution, liability definition, and legal evidence.
[0006] The peanut aflatoxin random forest risk early warning model (10.3864 / j.issn.0578-1752.2022.17.013) developed by a research team from China Agricultural University achieved a sensitivity of 85.61% on the independent validation set. However, this model is only applicable to peanut crops and focuses on the pre-harvest field stage, lacking the ability to model the dynamic risk evolution in the storage process. While the CSGNN model (10.3390 / foods12051048) employs a graph neural network architecture, its graph construction is based on the similarity measurement of chemical indicators between samples, lacking support from physical spatial meaning. Summary of the Invention
[0007] In summary, this invention addresses the technical problems of fragmented mechanistic data, neglect of spatial topology, and insufficient source interpretation in existing aflatoxin risk warning systems by providing a corn feed aflatoxin risk warning and source tracing system and method.
[0008] The technical solution of the present invention to solve the above-mentioned technical problems is as follows: In a first aspect, the present invention provides a method for early warning and source tracing of aflatoxin risk in corn feed, comprising the following steps: Environmental parameter data, including temperature, humidity, CO2 concentration, VOCs concentration and grain pile moisture content, are collected through a sensor network and uploaded to the data processing center at preset time intervals. Based on the collected environmental parameter data, the risk derivation characteristics of each storage node were calculated using a mold growth kinetic model, including the duration of risk (TRW) and the cumulative risk intensity (I). an And the mold growth rate μ; Obtain quality information from the source of the supply chain, including climate data of the place of origin, transportation conditions data, and warehousing quality inspection data, and generate source quality risk vectors through graph embedding networks; A composite graph structure for constructing a warehouse network is provided, comprising physical adjacency edges and biological propagation edges. The physical adjacency edges are constructed based on the geometric distance between warehouse rooms and the ventilation connection relationship, while the biological propagation edges are constructed based on the spore concentration field and spatial decay function simulated by CFD. The risk-derived features, source quality risk vector, and composite graph structure are input into the source quality-driven dynamic gated spatiotemporal graph neural network model, which outputs the aflatoxin exceedance probability sequence of each storage node within a future preset time window. Based on the above exceedance probability sequence, an adaptive threshold strategy is used to perform a four-level graded early warning. When an early warning is triggered, the spatiotemporal integral gradient attribution method with enhanced rate of change is used to quantify the proportion of responsibility for the three elements: source quality, spatial propagation, and self-management. Based on graph centrality analysis and digital twin simulation, key nodes are identified and a cost-optimal, precise intervention plan is output.
[0009] Furthermore, the mold growth kinetic model is the Ratkowsky modified equation: , Where μ is the specific growth rate, T is the temperature, and a t f is the water activity. t This is the temperature response function. Let f be the water activity response function. ph f is the pH response function. inhilitor This is the inhibitor concentration response function.
[0010] Furthermore, the weight calculation formula for the biological propagation edge is as follows: , in Let S be the spore transport probability, S be the environmental suitability function, D be the distance-time joint decay function, and O be the orientation factor.
[0011] In a preferred embodiment, the source quality-driven dynamic gated spatiotemporal graph neural network model includes: The GraphSAGE layer performs message passing and neighbor aggregation; The dynamic gating layer calculates the gating signal based on the source quality risk vector, historical hidden states, and the rate of change of hidden states, thereby achieving adaptive fusion of historical memory and current observation. Temporal convolutional network layers utilize a causal dilated convolutional architecture to capture multi-scale temporal dependencies; The prediction head layer is used to output the overshoot probability sequence.
[0012] In a preferred embodiment, the formula for calculating the gate signal of the dynamic gating layer is: , in As the source quality risk vector, In hidden state, This represents the rate of change of the hidden state.
[0013] In a preferred embodiment, the rate-of-change-enhanced spatiotemporal integral gradient attribution method includes: The standard integral gradient IG is calculated by integrating from the reference point to the actual input along a straight path. Introducing a rate of change weighting factor Calculate the integral gradient of the rate of change. ; Temporal attribution is obtained by integrating along the time dimension, and spatial attribution is obtained by aggregating attention along the GNN layers. Spatiotemporal fusion is performed based on the spatiotemporal adjustment coefficient, and the output is the proportion of three-dimensional responsibility: source quality, spatial propagation, and self-management.
[0014] In a preferred embodiment, the adaptive threshold strategy includes: The operation threshold is dynamically optimized based on the historical false alarm rate to keep the false positive rate at the preset target level. The probability of exceeding the standard is mapped to a four-level response, including green for normal monitoring, blue for attention and tracking, yellow for enhanced inspection, and red for immediate intervention; When the probability rise rate exceeds a preset threshold and the current probability exceeds a base threshold, the response level is automatically upgraded.
[0015] In a preferred embodiment, the digital twin simulation includes the steps of: Solving the velocity field distribution of the warehouse space based on a CFD model; Spore concentration field evolution was simulated based on convection-diffusion equations; Coupled fungal growth kinetics model for predicting biomass and toxin accumulation; Reinforcement learning algorithms are used to optimize intervention parameters, with the risk reduction and cost-benefit ratio serving as the reward signal.
[0016] On the other hand, the present invention provides a risk early warning and traceability system for aflatoxin in corn feed, comprising the following modules: The multi-source heterogeneous data feature engineering module collects warehouse environment data in real time through sensor networks, calculates risk-derived features based on the mold growth kinetics model, and generates source quality risk vectors through graph embedding networks. The spatiotemporal risk prediction module, which integrates mechanistic data, constructs a composite graph structure for the warehousing network and outputs an excess probability sequence based on a source quality-driven dynamic gated spatiotemporal graph neural network model. The interpretable risk decision-making and tracing module performs hierarchical early warning based on an adaptive threshold strategy, quantifies the proportion of ternary responsibility using a spatiotemporal integral gradient attribution method with enhanced rate of change, and outputs precise intervention plans based on graph centrality analysis and digital twin simulation.
[0017] Preferably, the multi-source heterogeneous data feature engineering module includes the following sub-modules: The environmental data encoding submodule constructs a sensor network and embeds a mold growth dynamics model to calculate risk-derived characteristics in real time. The supply chain data embedding submodule uses heterogeneous network embedding technology to generate source quality risk vectors; the pollution propagation graph construction submodule constructs a dual composite graph structure of physically adjacent edges and biological propagation edges.
[0018] Preferably, the spatiotemporal risk prediction module for mechanism data fusion includes the following sub-modules: The physical information-enhanced graph convolutional network submodule, based on a dynamic gating mechanism driven by source quality risk vectors, achieves deep spatiotemporal coupling between upstream supply chain quality information and downstream warehousing environmental conditions. The temporal convolutional network submodule, based on the causal dilated convolutional architecture, captures multi-scale risk evolution trends in parallel while ensuring temporal causality.
[0019] Compared with the prior art, the present invention has at least the following beneficial effects: This invention accurately characterizes the interaction effects of the corn source storage environment through a source quality-driven dynamic gating mechanism, enabling the model to adapt to risk evolution patterns under different quality input conditions and achieve early warning 5 to 7 days in advance, which is a significant improvement over the 2 to 3 days early warning of traditional methods.
[0020] In a preferred embodiment, the present invention achieves an F1-score of 0.87 by explicitly modeling the spatial propagation effect through a composite graph structure and by reasonably constraining the prediction space through physical mechanisms. This represents a 21% improvement over the traditional LSTM baseline of 0.72, a 34% reduction in out-of-distribution generalization error, and an increase in recall rate from 0.65 to 0.91 in extreme scenarios.
[0021] This invention uses a spatiotemporal integral gradient attribution method with enhanced rate of change to quantitatively distinguish between three types of responsibility: source quality, spatial propagation, and self-management. The attribution results are 88% consistent with expert experience, providing objective technical evidence for the determination of responsibility for quality accidents.
[0022] This invention utilizes digital twin simulation and reinforcement learning optimization to automatically identify key nodes and recommend the most cost-effective and precise intervention solutions. It supports the pre-simulation of the effects of various intervention measures such as ventilation control, batch isolation, and fumigation, providing a quantitative pre-assessment tool for management decisions. Attached Figure Description
[0023] Figure 1 A schematic diagram of the framework of a corn feed aflatoxin risk early warning and traceability system provided by the present invention; Figure 2 This is a schematic diagram of the structure of the multi-source heterogeneous data feature engineering module provided by the present invention; Figure 3 A schematic diagram of the framework of the source quality-driven dynamic gated spatiotemporal graph neural network model provided by the present invention; Figure 4 This is a comparison chart of the risk warning effects of Embodiment 1 of the present invention; Figure 5 This is a visualization of the CRIG attribution results in Embodiment 2 of the present invention; S1 Multi-source heterogeneous data feature engineering module, S2 Mechanism-data fusion spatiotemporal risk prediction module, S3 Explainable risk decision-making and source tracing module, S11 Environmental data encoding, S12 Supply chain data embedding, S13 Polluting vessel map construction, S21 Physical information enhancement GNN, S22 Wind sequence convolutional network, S23 Temporal convolutional network GNN, S31 Risk early warning submodule, S32 Contribution attribution CR-IG, S33 Intervention decision-making submodule. Detailed Implementation
[0024] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0025] In the description of this invention, the terms "first" and "second" are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of indicated technical features. Thus, a feature defined as "first" or "second" may explicitly or implicitly include one or more of the stated features. In the description of this invention, "a plurality of" means two or more, unless otherwise explicitly specified.
[0026] In the description of this invention, the term "for example" is used to mean "used as an example, illustration, or description." Any embodiment described as "for example" in this invention is not necessarily to be construed as being more preferred or advantageous than other embodiments. The following description is provided to enable any person skilled in the art to make and use the invention. Details are set forth in the following description for purposes of explanation. It should be understood that those skilled in the art will recognize that the invention can be made without using these specific details. In other instances, well-known structures and processes will not be described in detail to avoid obscuring the description of the invention with unnecessary detail. Therefore, the invention is not intended to be limited to the embodiments shown, but is consistent with the broadest scope of the principles and features disclosed herein.
[0027] Example 1 A large grain depot's cluster of 30 warehouses intelligent early warning system This embodiment is applied to a grain reserve warehouse, which is responsible for the temporary storage of corn. The warehouse consists of 30 single-story warehouses arranged in a 3×10 matrix, with a longitudinal spacing of 15m and a lateral spacing of 30m. Each warehouse has a capacity of 5,000 tons, and the total storage capacity is approximately 126,000 tons. The ventilation system uses a central ventilation corridor that runs north-south, connecting all warehouse ventilation openings. The source of incoming grain is 70% locally grown new grain and 30% transported from neighboring provinces, of which 15% of batches were harvested after rain, with an initial moisture content of 14% to 16%.
[0028] A method for early warning and source tracing of aflatoxin risk in corn feed, comprising the following steps: Step 1: Data Acquisition and Preprocessing SHT35 temperature and humidity sensors (accuracy ±0.1℃ / ±1.5%RH, 6 points / warehouse), SenseAir S8 CO2 sensors and Alphasense PIDAH VOCs sensors (1 point / warehouse), and hot-wire anemometers (0 to 20 m / s, deployed at ventilation openings) are deployed in each warehouse. Data is collected raw every 5 minutes and then aggregated by an edge computing node (NVIDIA Jetson Xavier) and uploaded every 1 hour.
[0029] Data cleaning was performed, outliers were removed using the 3σ criterion, and single-point outliers were filled with the median of adjacent spatiotemporal points; missing values were interpolated linearly, and time periods with a missing rate exceeding 10% were marked as data quality degradation; all continuous features were normalized to [0,1] using MinMax.
[0030] Step 2: Derivation of physical features The mold growth rate was calculated in real time using the calibrated Ratkowsky modified equation: ; These parameters are based on laboratory isolation and identification of historical moldy samples from this library (dominant species being Aspergillusflavus NRRL 3357), at 15 to 35°C and 0.82 to 0.95 a. t The prediction error is less than 12% within the validation range.
[0031] The risk accumulation intensity integral adopts trapezoidal numerical integration, and the time window is dynamically adjusted according to the TRW status: when TRW is less than 12 hours, the integration window is 72 hours; when 12 hours is less than or equal to TRW and less than 36 hours, the integration window is 48 hours; when TRW is greater than or equal to 36 hours, the integration window is 24 hours.
[0032] Step 3: Construction of a pollution propagation map The nodes include 30 warehouses, with a feature dimension F=12, including mean / variance of temperature (2D), mean / variance of humidity (2D), grain pile moisture (1D), CO2 concentration (1D), VOCs concentration (1D), duration of risk (TRW) (1D), and cumulative risk intensity I. an (1-dimensional), source quality vector (reduced to 1-dimensional by PCA), number of historical exceedances (1-dimensional), ventilation status (1-dimensional), and warehouse age (1-dimensional).
[0033] There are 87 physically adjacent edges with an Euclidean distance of less than 50m and no obstacles.
[0034] Biological propagation edges, based on CFD simulation of spore concentration field, with a threshold C greater than 10³ spores / m³, totaling 156 edges.
[0035] Edge weight initialization: .
[0036] Step 4: Training the SQDGSTGNN model The SQDGSTGNN model architecture uses a 3-layer GraphSAGE with hidden dimensions [64, 128, 256] and a mean aggregation function; a 2-layer MLP for dynamic gating with 128 hidden dimensions and 576 input dimensions; a 4-layer residual block TCN with an inflation rate of [1, 2, 4, 8] and a receptive field coverage of 15 steps (approximately 2.5 hours); a dropout rate of 0.2; a weighted BCE loss function with a positive sample weight of 5; and an AdamW optimizer with a learning rate of 1e3 and a weight decay of 1e4.
[0037] Training data: 2020-2023, 120 silos / year, approximately 1 million samples, using time-series cross-validation. The best validation performance occurred at epoch 167, with validation set F1=0.87 and AUCPR=0.81.
[0038] Step 5: Attribution Analysis and Decision Output Typical output example The probability of exceeding the limit on day 7 in warehouse No. 3 is 0.82.
[0039] The attribution result was that the source quality contributed 42% (this batch came from a post-rain harvest area with an initial moisture content of 15.8%). Located at the 85th percentile of the historical distribution); neighborhood transmission contribution of 35% (related to the ventilation strength of Warehouse No. 2, w) 23 =0.73, spore input flux 2.3×10 4 spores / m 3 / h); Self-management contribution rate 23% (average ventilation rate of 1.2m in the past 72 hours). 3 / s, standard 3.0m 3 / s, the temperature at the center of the grain pile is 3.5℃ higher than the average.
[0040] Intervention Recommendations The system identified Warehouse 3 as a critical node (ranked 2nd in Betweenness Centrality; risk propagation simulation showed that removing it reduced the overall network risk by 67%). The recommended solution is batch isolation (100% isolation, transfer to a low-temperature warehouse, cost 1800 yuan) plus area ventilation (increase ventilation in warehouses 2, 3, and 4 to 15 m³). 3 / s, cost 120 yuan / day), the expected risk probability will drop to 0.31 within 7 days, the risk of the entire network will be reduced by 67%, and the total cost will be 2150 yuan.
[0041] Example 2 Identification of critical early warning moments based on rate of change sensitivity This example performs an attribution analysis on the risk surge event from August 12th to 15th, 2024, as described in Example 1. The risk probability of Warehouse 3 jumped from 0.31 to 0.78, requiring the identification of key driving factors and verification of the effectiveness of CRIG.
[0042] First, calculate the rate of change of each characteristic time series. ; Then identify the peak moment of the rate of change. , to obtain t =August 13, 06:00; Finally, standard IG and CRIG attribution were performed on the same sample respectively, and the results were compared and verified with on-site operation and maintenance records and expert experience.
[0043] This embodiment found that CRIG correctly identified "ventilation system malfunction leading to a sudden increase in humidity" as the primary factor (contribution 47%), with specific evidence including: humidity change rate in t The peak value was reached at 0.15 m / min (historical average 0.02 m / min), and the ventilation rate decreased from 3.0 m. 3 / s dropped sharply to 0.5m 3 / s (sensor record). The standard IG only gives a 29% contribution and misclassifies temperature fluctuations as the primary factor. This case validates the crucial value of rate of change sensitivity in identifying key drivers at critical moments of risk transition.
[0044] Example 3 Risk Collaborative Early Warning Network of Cross-Regional Grain Depot Alliance This embodiment constructs a cross-warehouse risk collaborative early warning system for three geographically dispersed grain depots (Warehouse A with 30 warehouses, Warehouse B with 20 warehouses, and Warehouse C with 15 warehouses). The intra-warehouse graph structure is the same as in Embodiment 1, while the inter-warehouse graph structure is constructed based on the transport batch association edges, with the inter-warehouse edge weights as follows: , Overall transport volume, time decay, and quality correlation.
[0045] This embodiment utilizes a federated learning framework, with each repository training locally and sharing graph structure parameters, while simultaneously protecting data privacy. The collaborative early warning mechanism automatically updates the source quality vector of the corresponding node in repositories B and C when a high-risk batch leaves repository A. In this embodiment, a batch (with a high source quality vector) from repository A is transported to repository B by rail over a 48-hour period. The system marks the risk status of this batch when it leaves repository A, and automatically receives the update signal when it enters repository B. It then adjusts the source quality vector of this batch using exponential decay (α=0.8 corresponds to 48-hour decay) and triggers local graph reconstruction and risk reassessment in repository B, achieving dynamic tracking of risk as goods move.
[0046] Example 4 Digital twin-driven intervention effect preview This embodiment uses digital twin simulation to evaluate the cost-benefit trade-offs of different options for intervention decisions in Warehouse No. 3 in Embodiment 1. The digital twin components include: a warehouse environment CFD model (RANS kε turbulence model) based on OpenFOAM, with the input ventilation rate Q and output velocity field u(x,y,z); a spore diffusion model based on the convection-diffusion equation, with the input velocity field and output spore concentration field C(x,t); and a mold growth model coupled with Ratkowsky dynamics, with input spore concentration, temperature, and water activity, and output biomass X(t) and toxin P(t).
[0047] Intervention parameters are parameterized, and mechanical ventilation Q∈[0,20] m 3 / s, batch isolation η∈[0,1], fumigation agent C∈[0,500]ppm. The PPO reinforcement learning algorithm is used to solve for the optimal policy, with the state being a risk field and resource constraints, and the reward function... .
[0048] Output the optimal solution Ventilation 12 m 3 Adding 80% isolation to the batch reduces the expected risk by 67% at a total cost of 3200 yuan. This cost-effectiveness ratio is better than the pure ventilation solution (45% risk reduction, 2800 yuan cost) and the pure isolation solution (55% risk reduction, 4500 yuan cost). Digital twin simulation provides a quantitative pre-assessment tool for management decisions, avoiding the blindness of traditional experience-based decision-making.
[0049] It should be noted that the descriptions of each embodiment in the above embodiments have different focuses. For parts that are not described in detail in a certain embodiment, please refer to the relevant descriptions in other embodiments.
[0050] Those skilled in the art will understand that embodiments of the present invention can be provided as methods, systems, or computer program products. Therefore, the present invention can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present invention can take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0051] This invention is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded computer, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart illustrations. Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.
[0052] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.
[0053] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.
[0054] Although preferred embodiments of the invention have been described, those skilled in the art, once they have learned the basic inventive concept, can make other changes and modifications to these embodiments.
[0055] Obviously, those skilled in the art can make various modifications and variations to this invention without departing from its spirit and scope. Therefore, if these modifications and variations fall within the scope of this invention and its equivalents, this invention also intends to include these modifications and variations.
Claims
1. A method for early warning and traceability of aflatoxin risk in corn feed, characterized in that, Includes the following steps: The storage environment parameter data of corn is collected through a sensor network and uploaded to the data processing center at preset time intervals. Based on the collected storage environment parameter data, the risk derivation characteristics of each storage node are calculated using a mold growth kinetic model, including the duration of risk (TRW) and the cumulative risk intensity (I). an And the mold growth rate μ; Obtain quality information from the source of the supply chain and generate source quality risk vectors through graph embedding networks; A composite graph structure for constructing a warehouse network is provided, comprising physical adjacency edges and biological propagation edges. The physical adjacency edges are constructed based on the geometric distance between warehouse rooms and the ventilation connection relationship, while the biological propagation edges are constructed based on the spore concentration field and spatial decay function simulated by CFD. The risk-derived features, source quality risk vector, and composite graph structure are input into the source quality-driven dynamic gated spatiotemporal graph neural network model, which outputs the aflatoxin exceedance probability sequence of each storage node within a future preset time window. Based on the above exceedance probability sequence, an adaptive threshold strategy is used to perform a four-level graded early warning. When an early warning is triggered, a spatiotemporal integral gradient attribution method with enhanced rate of change is used to quantify the proportion of responsibility for source quality, spatial propagation, and self-management. Based on graph centrality analysis and digital twin simulation, key nodes are identified and a cost-optimal, precise intervention plan is output.
2. The method for early warning and traceability of aflatoxin risk in corn feed according to claim 1, characterized in that, The mold growth kinetic model is the Ratkowsky modified equation: , Where μ is the specific growth rate, T is the temperature, and a t f is the water activity. t This is the temperature response function. Let f be the water activity response function. ph f is the pH response function. inhilitor This is the inhibitor concentration response function.
3. The method for early warning and traceability of aflatoxin risk in corn feed according to claim 1, characterized in that, The formula for calculating the weight of the biological propagation edge is: , in Let S be the spore transport probability, S be the environmental suitability function, D be the distance-time joint decay function, and O be the orientation factor.
4. The method for early warning and traceability of aflatoxin risk in corn feed according to claim 1, characterized in that, The source quality-driven dynamic gated spatiotemporal graph neural network model includes: The GraphSAGE layer performs message passing and neighbor aggregation; The dynamic gating layer calculates the gating signal based on the source quality risk vector, historical hidden states, and the rate of change of hidden states, thereby achieving adaptive fusion of historical memory and current observation. Temporal convolutional network layers utilize a causal dilated convolutional architecture to capture multi-scale temporal dependencies; The prediction head layer is used to output the overshoot probability sequence.
5. The method for early warning and traceability of aflatoxin risk in corn feed according to claim 4, characterized in that, The formula for calculating the gate control signal of the dynamic gate control layer is as follows: , in As the source quality risk vector, In hidden state, This represents the rate of change of the hidden state.
6. The method for early warning and traceability of aflatoxin risk in corn feed according to claim 1, characterized in that, The spatiotemporal integral gradient attribution method with enhanced rate of change includes: The standard integral gradient IG is calculated by integrating from the reference point to the actual input along a straight path. Introducing a rate of change weighting factor Calculate the integral gradient of the rate of change. ; Temporal attribution is obtained by integrating along the time dimension, and spatial attribution is obtained by aggregating attention along the GNN layers. Spatiotemporal fusion is performed based on the spatiotemporal adjustment coefficient, and the output is the proportion of three-dimensional responsibility: source quality, spatial propagation, and self-management.
7. The method for early warning and traceability of aflatoxin risk in corn feed according to claim 1, characterized in that, The adaptive threshold strategy includes: The operation threshold is dynamically optimized based on the historical false alarm rate to keep the false positive rate at the preset target level. The probability of exceeding the standard is mapped to a four-level response, including green for normal monitoring, blue for attention and tracking, yellow for enhanced inspection, and red for immediate intervention; When the probability rise rate exceeds a preset threshold and the current probability exceeds a base threshold, the response level is automatically upgraded.
8. The method for early warning and traceability of aflatoxin risk in corn feed according to claim 1, characterized in that, The digital twin simulation includes the following steps: Solving the velocity field distribution of the warehouse space based on a CFD model; Spore concentration field evolution was simulated based on convection-diffusion equations; Coupled fungal growth kinetics model for predicting biomass and toxin accumulation; Reinforcement learning algorithms are used to optimize intervention parameters, with the risk reduction and cost-benefit ratio serving as the reward signal.
9. A risk warning and traceability system for aflatoxin in corn feed, characterized in that, Includes the following modules: The multi-source heterogeneous data feature engineering module collects warehouse environment data in real time through sensor networks, calculates risk-derived features based on the mold growth kinetics model, and generates source quality risk vectors through graph embedding networks. The spatiotemporal risk prediction module, which integrates mechanistic data, constructs a composite graph structure for the warehousing network and outputs an excess probability sequence based on a source quality-driven dynamic gated spatiotemporal graph neural network model. The interpretable risk decision-making and tracing module performs hierarchical early warning based on an adaptive threshold strategy, quantifies the proportion of ternary responsibility using a spatiotemporal integral gradient attribution method with enhanced rate of change, and outputs precise intervention plans based on graph centrality analysis and digital twin simulation.