Biosensor identification and prediction method and system based on deep learning
By reconstructing environmental gradient maps using a multimodal fusion Transformer and generative diffusion model, the problem of insufficient utilization of environmental gradients in pest monitoring was solved, enabling refined tracking of individual pest activities and migration prediction, thus improving the accuracy and control efficiency of grain storage pest monitoring.
Patent Information
- Application Number
- CN202511802898.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-12-03
- Publication Date
- 2026-02-27
AI Technical Summary
Existing technologies struggle to effectively utilize environmental gradient information in pest monitoring, making it impossible to achieve refined and dynamic tracking and prediction of pest behavior, resulting in a lack of precision and foresight in control measures.
A multimodal fusion Transformer is used to reconstruct continuous fields such as temperature and humidity gases and VOCs, generating multi-scale environmental gradient maps. Based on environmental suitability and pressure, potential functions and force fields are constructed. Generative diffusion models are used to sample and update individual trajectories online, enabling real-time identification and migration prediction of pest activities.
It enables real-time identification and migration prediction of individual pest activities, generates a quantitative comprehensive risk index and graded early warning, provides a basis for targeted intervention, and improves the accuracy and timeliness of prevention and control.
Smart Images

Figure CN121580134A_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the field of pest identification, prediction and food storage safety assurance, and in particular to a biological sensor identification and prediction method and system based on deep learning. BACKGROUND
[0002] Due to its closed and stable characteristics, grain storage and other agricultural product storage environments are prone to be invaded by various types of stored grain pests, causing serious economic losses. For a long time, the monitoring of stored grain pests has mainly relied on manual inventory, physical traps (such as sticky traps and attractors), and simple acoustic or image recognition technology. Although these methods can indicate the presence of pests, they generally have low efficiency, poor timeliness, difficulty in achieving early warning, limited monitoring range, and inability to accurately assess the severity of pest infestation. In order to overcome the above shortcomings, researchers have begun to use various biological sensors to monitor key physical and chemical parameters in the storage environment, such as temperature, humidity, oxygen concentration, carbon dioxide concentration, and the composition and changes of volatile organic compounds (VOCs). Changes in these parameters, especially specific components of VOCs, are often closely related to the physiological activities, metabolic products, and reproductive behavior of pests. By monitoring these parameters, it can be inferred to some extent whether pests exist or their activity level.
[0003] Although biological sensor technology provides a new perspective for pest monitoring, existing technologies still have significant bottlenecks in data analysis and information utilization. Most existing methods tend to monitor a single or a small number of environmental parameters in isolation and statically. For example, temperature anomalies in a certain area may be detected to determine whether pests are gathering, or overall trends in VOCs sensor readings may be analyzed. However, the physical and chemical environment inside a grain pile is not uniformly distributed, but rather presents a complex spatial gradient. For example, there are differences in temperature, humidity, and oxygen content between the center and the surface of the grain pile, and pests at different locations may also produce VOCs with specific labels. Studies have shown that pest activity is closely related to these environmental gradients, and they are often attracted or repelled by specific gradients (such as temperature and humidity interfaces, oxygen concentration change points), and they tend to move, migrate or gather in areas where these gradients change significantly. Existing technologies fail to fully recognize and effectively utilize this "environmental gradient" information. They mainly treat sensor data as a simple description of background parameters, lacking the ability to convert these discrete parameter points into an "environmental map" or "force field" that can indicate pest behavior. Therefore, the above methods can only provide limited environmental indications, and cannot effectively link them directly to the "location" or "direction" of pests.
[0004] In recent years, artificial intelligence technology, especially deep learning, has shown great potential in the field of biosensor data analysis. Artificial intelligence models have been used to identify patterns in sensor data, distinguish between different types of VOCs, and even predict the overall risk of insect infestation. However, the application of artificial intelligence in grain pest monitoring is still largely limited to "pattern recognition" or "classification" of sensor parameters, and has not achieved fine and dynamic "behavior insight" of individual or group pests. Existing artificial intelligence algorithms may be able to "identify" the possibility of insect infestation in a certain area, but they still have the following problems: (1) It is difficult to construct a "gradient map" reflecting the spatial gradient distribution from multi-dimensional sensor data in real time. (2) It is difficult to simulate the real "force" and movement behavior of pests under the influence of environmental attraction and repulsion forces in a complex gradient field. (3) It is unable to track specific pest individuals or groups, and accurately predict their future "migration path" and "aggregation area". (4) Ultimately, the prevention and control measures are still based on macroscopic judgment, lacking fine "directedness" and "prospective", and cannot achieve on-demand and precise intervention.
[0005] Therefore, how to provide a biosensor identification method capable of solving the above technical problems is a problem that those skilled in the art need to solve. SUMMARY
[0006] One object of the present application is to provide a deep learning-based biosensor identification and prediction method. To overcome the shortcomings of the prior art, such as isolated and static processing of multi-modal sensor data, difficulty in constructing a spatial gradient map, inability to depict the force and movement of pests in a complex environment, difficulty in individual-level tracking and migration prediction, and lack of direction in rough warning, a method is proposed for reconstructing continuous fields of temperature, humidity, and VOCs using multi-modal fusion Transformer and generating multi-scale environmental gradient maps, constructing potential functions and force fields based on environmental suitability and stress, and performing individual trajectory sampling and online updating using a force-guided diffusion model. This method realizes the conversion of discrete sensor readings into a closed-loop inference of "force field-trajectory-risk". The method can identify attractors, repellents, and migration channels in real time at the scale of the warehouse body, track pest individual activities, and predict migration direction, speed, and potential aggregation location, thereby forming a quantitative comprehensive risk index and graded warning, and providing a basis for targeted interventions such as trapping, ventilation, temperature and humidity control, and pesticide application.
[0007] According to the deep learning-based biosensor identification and prediction method of the present application, the method comprises the following steps:
[0008] S1, receiving multi-modal real-time detection data from a plurality of biosensors for monitoring a plurality of specific physical and chemical parameters in a storage environment, and preprocessing the multi-modal detection data to obtain an initial input data set;
[0009] S2, processing the preprocessed initial input data set using a multi-modal fusion Transformer model to identify and quantify the multi-dimensional physical and chemical parameter differences at different spatial positions in the storage environment, and generating an environmental gradient map reflecting the spatial gradient distribution;
[0010] S3, based on the environmental gradient map and the initial input data, identifying whether there are specific environmental features related to pest activity, and analyzing the environmental attraction and repulsion forces on the pests in the gradient map;
[0011] S4, when identifying specific environmental features related to pest activity and calculating environmental attraction and repulsion forces, based on a generative diffusion model, using the environmental gradient map and the analyzed environmental attraction and repulsion forces, simulating the behavioral response of pests, tracking their individual activity trajectories, and predicting their migration direction, speed and potential aggregation location in the future;
[0012] S5, based on the identified specific environmental features related to pest activity, individual activity trajectories, migration direction, and predicted aggregation location, evaluating the occurrence degree and diffusion risk of pests in the storage environment, calculating and outputting the corresponding risk level, and generating a real-time warning signal when the risk level reaches a preset threshold;
[0013] S6, when receiving the real-time warning signal or according to the risk level evaluation result, based on the environmental gradient map, the tracked individual activity trajectory and the predicted aggregation location information, generating or optimizing the targeted strategy of prevention and control intervention in the storage environment.
[0014] Optionally, the multi-modal real-time detection data includes temperature, humidity, gas composition, volatile organic compounds;
[0015] The preprocessing specifically comprises: registering and spatial coordinate calibrating the plurality of biosensors to record unique identification, three-dimensional position and modal type; receiving data in real time under a unified reference clock and stamping a global timestamp for each record; performing time synchronization and resampling on data of different modalities to align each modality sequence to a preset sampling interval; carrying out anomaly detection and data cleaning, removing noise points and distorted samples based on physical boundaries, statistical thresholds and neighborhood consistency; implementing baseline drift correction and cross-sensitivity compensation, compensating for drift based on zero-gas baseline for VOCs channels and combining temperature and humidity for response correction; performing denoising filtering, sequentially using low-pass filtering and wavelet threshold denoising to suppress high-frequency noise; performing spatio-temporal neighborhood weighted interpolation on missing and intermittent data to maintain sequence continuity; extracting features such as amplitude, mean, standard deviation, slope and integral area in a sliding time window; normalizing and scaling the multi-modal features; and performing spatio-temporal alignment and sample packaging according to a preset sliding time window to form an initial input data set containing modality identification, spatial coordinates, time index and quality weight.
[0016] Optionally, the environmental gradient map specifically comprises: grouping the initial input data set according to sensing modalities, spatial coordinates and time indexes and tensorizing it into sequence tokens, each modality obtaining a unified dimension representation through a feature encoder, and adding spatial and temporal position encodings generated from three-dimensional coordinates and timestamps; constructing adjacency relationships based on spatial distances between sensors and known ventilation and airflow topologies, and calculating relative position biases and neighborhood weights, inputting the above tokens into a multi-modal fusion Transformer to perform cross-modality attention to realize information interaction and adaptive fusion of weights, and then propagating and aggregating in the spatial and temporal dimensions through spatio-temporal self-attention to form globally consistent node representations; subsequently, using a spatial reconstruction decoding head to map the non-uniformly distributed node representations to a preset regular grid, reconstructing continuous scalar fields of temperature, humidity, oxygen, carbon dioxide and VOCs, and masking the grid outside the warehouse body; on this basis, calculating the difference and first-order spatial gradient vector at each parameter grid, and constructing a multi-scale gradient representation through upsampling and feature fusion; at the same time, estimating the grid-level confidence based on the attention weight distribution, reconstruction residual and model ensemble variance and adding it as a quality weight; finally outputting an environmental gradient map containing multi-parameter gradient vectors, gradient amplitudes, direction information and quality weights.
[0017] Optionally, the specific environmental feature related to pest activity is specifically: aligning the environmental gradient map with the original multi-modal real-time detection data in the same spatial grid and time window, extracting temperature, humidity, oxygen, carbon dioxide, VOCs, and their first-order gradient, second-order difference, and gradient direction relationship features and normalizing them; obtaining environmental suitability and environmental pressure according to the weights determined by training, respectively, constructing a potential function field under the constraints of value and monotony, and deriving a stress field therefrom; through potential field local extremum and stress streamline density analysis, under the condition of meeting the suitability and pressure threshold, the connected region of local potential minimum is judged as an attractor, the local maximum is judged as a repeller, the center line of the connected region with a threshold of streamline crossing density is judged as a migration channel, and the saddle point with an alternating trend of rising and falling is identified; at the same time, the trap trigger, VOCs increment anomaly, and temperature and humidity mutation are mapped as observation evidence, the confidence of the candidate region is weighted and exponentially smoothed, and the stable target region is retained through spatial overlap degree, centroid displacement, and potential value stability test of consecutive time windows; if there is any target region that passes the consistency test, it is determined that there is a specific environmental feature related to pest activity;
[0018] The analysis of the environmental attraction and repulsion force received by the pest in the gradient map is specifically: in the gradient map, the potential function field constructed is regarded as a scalar potential, the force direction is defined as the steepest direction of the potential function, and the force intensity is positively related to the spatial variation rate of the potential function; when the air flow sensor is configured, the external flow field estimated by the air flow sensor is added as an additional force component; when the force vector points to the identified local minimum connected region of the potential function, it is defined as the environmental attraction force to the region; when the force vector is away from the local maximum connected region of the potential function, it is defined as the environmental repulsion force from the region; the strength of attraction and repulsion changes with the gradient amplitude of the potential function, and is jointly affected by the superimposed component of the external flow field.
[0019] Optionally, the simulated pest behavioral response specifically comprises: encoding the environmental gradient atlas, force field and target environmental features as conditional input, generating initial seed points with initial direction and speed at the center of attractant source, entrance of migration channel, nearest trapping trigger and abnormal position of VOCs, loading the trained generative diffusion model to perform force-guided diffusion sampling for a fixed prediction time and time step, generating trajectory sample set under boundary and dynamics constraints; then using particle filtering to fuse samples with current observation evidence and resample, scoring samples according to observation consistency, physical feasibility and model confidence, and selecting the highest score as the representative trajectory; constructing a direction histogram for the direction sequence of the representative trajectory within the prediction time and taking the main peak as the migration direction, and taking the median of the unit time displacement sequence as the speed estimate; meanwhile, collect all individual trajectory position points within the prediction time for fixed radius density clustering, identify high-density connected regions and take their centroids as potential aggregation positions, output corresponding aggregation radius and individual count, and give confidence levels for direction, speed and aggregation position based on sample dispersion, model internal confidence and observation consistency;
[0020] The target environmental features include attractant source, repellent source, migration channel and saddle point.
[0021] Optionally, the calculating and outputting of the corresponding risk level specifically comprises: aligning the target environmental features, force field and representative trajectory data in the same spatial grid and evaluation time window, and retaining grid quality weight and trajectory confidence weight; dividing the evaluation area according to fixed resolution and setting sliding evaluation window and historical comparison window; calculating the growth trend by surrounding the occurrence degree statistics trajectory points and forming individual density according to area standardization, combining aggregation count and radius, and comparing with the historical comparison window; calculating the entering flow along the identified migration channel according to the diffusion risk, and combining the channel length, channel internal force field strength and difficulty coefficient of boundary restriction for standardization, and estimating the predicted arrival time according to the representative trajectory speed and channel geometric distance and discretizing it into time period classification; weighting the environmental suitability, environmental pressure and force intensity in the region according to the grid quality weight; then weighting the individual density, aggregation strength, growth trend, entering flow, predicted arrival time classification, environmental suitability, environmental pressure and force intensity according to the preset weight to obtain a single comprehensive risk index, and deducting the uncertainty penalty item indicated by the trajectory dispersion and model internal confidence according to the preset weight; finally, dividing the comprehensive risk index into four risk levels according to the three thresholds determined and fixed in the training phase, to obtain the regional risk judgment.
[0022] Optionally, the generating or optimizing the targeting strategy specifically is: aligning the early warning, risk list, environmental gradient, stress field, representative trajectory and aggregation position in the same spatial grid and planning time window, selecting higher and high-risk areas as targets; setting the planning length, execution step and resource budget, maximizing the comprehensive risk reduction as the goal, imposing safety compliance, equipment, manpower, inventory, operation time window, fan, temperature and humidity control start-stop times, attractor minimum distance and boundary retreat distance and other constraints; based on the action library including attractor placement, adjustment, zoned ventilation, temperature control, humidity control, fixed-point, differential application and parameter template generation candidate schemes, high-risk including attractor + ventilation + humidity control + fixed-point application, higher-risk including attractor + ventilation + humidity control, space around the potential aggregation point and along the migration channel, the ventilation direction is opposite to the main direction of the stress; using integer linear programming to determine the action and its space-time parameters under the constraints, and after solving, the conflicts and compliance are checked and resolved according to the priority of "application > ventilation > attractor"; mapping the strategy to the stress and suitability adjustment to carry out forward simulation, if the target area risk is not reduced to medium risk or below, then single re-optimization; finally output the targeting strategy including action type, location, quantity, intensity, duration, execution sequence and expected risk reduction and effective period and issue an archive.
[0023] According to an embodiment of the present application, a biological sensor identification and prediction system comprises the following modules:
[0024] A data acquisition and preprocessing module receives multi-modal real-time detection data from a plurality of biological sensors for monitoring a plurality of specific physical and chemical parameters in a storage environment, and performs preprocessing operations on the multi-modal detection data;
[0025] An environmental gradient map construction module processes the preprocessed detection data using a multi-modal fusion Transformers model to identify and quantify the multi-dimensional physical and chemical parameter differences at different spatial locations in the storage environment, and generates an environmental gradient map reflecting the spatial gradient distribution;
[0026] A target feature identification and gradient analysis module identifies whether there is a specific environmental feature related to pest activity based on the gradient map output by the multi-modal fusion Transformers model and the preprocessed detection data, and analyzes the environmental attraction and repulsion force received by the pest in the gradient map;
[0027] An individual migration path tracking and prediction module: when the target feature recognition and gradient analysis step identifies the target features related to pest activities and calculates the environmental attraction and repulsion forces, based on the generative diffusion model, the environmental gradient map and the analyzed environmental attraction and repulsion forces are used to simulate the behavioral response of pests, track the individual activity trajectory, and predict the migration direction, speed and potential aggregation location of pests in the future period of time;
[0028] A risk level assessment and early warning module: based on the specific environmental features identified in the target feature recognition and gradient analysis step, the migration trajectory tracked in the individual migration path tracking and prediction step, and the predicted aggregation location, the occurrence degree and diffusion risk of pests in the storage environment are evaluated, and the corresponding risk level is calculated and output; and when the risk level reaches a preset threshold, a real-time early warning signal is generated;
[0029] A control strategy optimization module: when receiving the real-time early warning signal or according to the risk level assessment result, based on the environmental gradient map, the tracked individual activity trajectory and the predicted aggregation location information, a targeted strategy for prevention and control intervention in the storage environment is generated or optimized.
[0030] The beneficial effects of the present application are:
[0031] (1) Fine spatial-behavior modeling and forward-looking early warning capability. Through multi-modal fusion Transformer, the data of temperature and humidity, oxygen / carbon dioxide and VOCs are spatiotemporally fused and reconstructed to generate multi-scale environmental gradient maps; combined with the potential function and force field constructed based on environmental suitability / pressure, and with the diffusion model guided by force, individual-level trajectory prediction and aggregation location determination are realized, completing the upgrade from "whether there is pest" to "where, how to migrate, when to arrive", significantly improving the accuracy and timeliness of early warning.
[0032] (2) Prediction robustness and controllable uncertainty. Through registration calibration, time synchronization, drift correction, noise reduction and interpolation, the uncertainty estimation and grid quality weight of multi-scale reconstruction are superimposed, and in the sampling / tracking stage, the synchronous observation evidence (trap triggering, VOCs anomaly, temperature and humidity mutation) and boundary, speed / acceleration physical constraints are fused, so that under the conditions of sensor noise, data missing and environmental heterogeneity, reliable gradient map, force field and trajectory results can still be stably output, thereby reducing false positives and result fluctuations.
[0033] (3) Risk-intervention closed loop and executability under resource constraints. Based on individual density, aggregation intensity, channel flow, environmental suitability / pressure, etc. Calculate the comprehensive risk index and grade the warning; Under the constraints of equipment capacity, safety compliance, inventory and operation time window, etc., use integer linear programming to generate targeted strategies such as trapping, zoned ventilation, temperature and humidity control, and pesticide application, and through forward simulation verification and necessary re-optimization, the identification and prediction results are converted into executable plans with spatial and temporal parameters and intensity parameters, improving prevention and control efficiency and reducing pesticide and energy costs. BRIEF DESCRIPTION OF DRAWINGS
[0034] The accompanying drawings are included to provide a further understanding of the application, and constitute a part of the specification, together with the embodiments of the application, to explain the application, and do not constitute a limitation on the application. In the drawings:
[0035] Figure 1 A flowchart of a biological sensor identification and prediction method based on deep learning proposed by the present application. DETAILED DESCRIPTION
[0036] The application will now be described in further detail with reference to the drawings. These drawings are simplified schematic diagrams that only schematically illustrate the basic structure of the application, and therefore only show the components related to the application.
[0037] Reference Figure 1 A biological sensor identification and prediction method based on deep learning, comprising:
[0038] S1, receiving multi-modal real-time detection data from a plurality of biological sensors, the biological sensors being used to monitor a plurality of specific physical and chemical parameters in a storage environment, and pre-processing the multi-modal detection data to obtain an initial input data set;
[0039] S2, processing the pre-processed initial input data set using a multi-modal fusion Transformer model to identify and quantify the multi-dimensional physical and chemical parameter differences at different spatial positions in the storage environment, and generating an environmental gradient map reflecting the spatial gradient distribution;
[0040] S3, based on the environmental gradient map and the initial input data, identifying whether there are specific environmental features related to pest activity, and analyzing the environmental attraction and repulsion forces experienced by the pests in the gradient map;
[0041] S4, when the specific environmental features related to pest activity are identified and the environmental attraction and repulsion forces are calculated, based on a generative diffusion model, using the environmental gradient map and the analyzed environmental attraction and repulsion forces, simulating the behavioral response of the pests, tracking their individual activity trajectories, and predicting their migration direction, speed and potential aggregation location in the future period of time;
[0042] S5. Based on the identified specific environmental characteristics, individual activity trajectories, migration directions, and predicted aggregation locations related to pest activities, assess the occurrence and spread risk of pests in the storage environment, calculate and output the corresponding risk level, and generate a real-time early warning signal when the risk level reaches a preset threshold.
[0043] S6. When the real-time early warning signal is received or the risk level assessment result is obtained, a targeted strategy for prevention and intervention in the storage environment is generated or optimized based on the environmental gradient map, the tracked individual activity trajectory and the predicted aggregation location information.
[0044] In this embodiment, the multimodal real-time detection data includes temperature, humidity, gas composition, and volatile organic compounds;
[0045] The preprocessing specifically includes: registering and spatially calibrating multiple biosensors to record unique identifiers, three-dimensional positions, and modal types; receiving data in real time under a unified reference clock and adding a global timestamp to each record; performing time synchronization and resampling on data from different modalities, aligning each modal sequence to a preset sampling interval; conducting anomaly detection and data cleaning, removing noise points and distorted samples based on physical boundaries, statistical thresholds, and neighborhood consistency; implementing baseline drift correction and cross-sensitivity compensation, performing drift compensation for VOCs channels based on a zero-air baseline and combining temperature and humidity for response correction; performing denoising filtering, sequentially using low-pass filtering and wavelet threshold denoising to suppress high-frequency noise; performing spatiotemporal neighborhood weighted interpolation on missing and discontinuous data to maintain sequence continuity; extracting features such as amplitude, mean, standard deviation, slope, and integral area within a sliding time window; normalizing and scaling multimodal features; and performing spatiotemporal alignment and sample packaging according to a preset sliding time window to form an initial input dataset containing modal identifiers, spatial coordinates, time indices, and quality weights.
[0046] Specifically, this implementation establishes a unified spatiotemporal processing link for multimodal sensing data such as temperature, humidity, oxygen, carbon dioxide, and VOCs. First, it completes sensor registration and spatial calibration, recording the unique identifier of each sensor. 3D coordinates With modal type And build a global timeline under a unified reference clock: ;
[0047] in For the first A global timestamp, The start time after alignment. For the preset sampling interval, and This represents the time step for the current batch.
[0048] To eliminate differences in sampling frequency between different devices, the original sequence is resampled to the above time axis for each sensor, preferably using linear interpolation: and ;
[0049] in For sensor indexing, For the first Sensor in resampled values, and They are respectively Two adjacent raw readings, and To correspond to the original timestamp, and For adjacent sample indexes, These are the interpolation coefficients;
[0050] Subsequently, anomaly detection and data cleaning are performed by combining physical boundaries, equipment self-inspection, and sliding statistical thresholds to mark and remove outlier and distorted samples, while generating anomaly masks to provide a basis for subsequent quality assessment; targeting For channels belonging to VOCs, compensation is performed to suppress baseline drift and the cross-sensitivity effects of temperature and humidity:
[0051] ;
[0052] in To compensate for the value, Baseline drift estimated for zero gas or historical stable periods. and These are the cross-sensitivity coefficients for temperature and humidity, respectively. and These are temperature and humidity readings at the same location. and For the corresponding reference baseline;
[0053] For non-VOCs channels, the compensated value is equal to the resampled value; to suppress high-frequency noise and transient glitches, first-order low-pass smoothing is performed on each channel: ;
[0054] in The smoothed value, As a smoothing factor, The timestamp is the previous timestamp, and the initial value is given by the first valid sample;
[0055] Furthermore, wavelet thresholding is used to perform soft thresholding on high-frequency components when necessary to further improve the signal-to-noise ratio. When there are missing or abnormal sampling points, interpolation is performed using a spatiotemporal neighborhood weighting approach. Spatial weights decay with the distance between sensors, and temporal weights decay with the time difference. Priority is given to using effective data of the same modality and physical proximity to maintain temporal continuity and spatial consistency. Subsequently, statistical and morphological features such as amplitude, mean, standard deviation, slope, and integral area are extracted within a sliding time window, and multimodal features are normalized according to preset minimum-maximum or standardization rules to achieve scale uniformity. The relevant normalization parameters are fixed during the training or calibration phase to ensure online consistency. Simultaneously, quality weights are generated based on the anomaly ratio within the window, sensor health status, and interpolation ratio for subsequent fusion and confidence control. Finally, the data will include... The normalized feature vectors and quality weights of the samples are spatiotemporally aligned and packaged according to a preset sliding time window to form the initial input dataset items for the multimodal fusion Transformer to call.
[0056] In this embodiment, the environmental gradient map is specifically implemented as follows: the initial input dataset is grouped and tensorized into sequence tokens according to sensing modality, spatial coordinates, and time index. Each modality obtains a unified dimensional representation through a feature encoder and is further encoded with spatial and temporal position codes generated from three-dimensional coordinates and timestamps. Adjacency relationships are constructed based on the spatial distance between sensors and known ventilation and airflow topology, and relative positional biases and neighborhood weights are calculated. The tokens are then input into a multimodal fusion Transformer to perform cross-modal attention to achieve information interaction and adaptive weight fusion. Subsequently, spatiotemporal self-attention is used to propagate and cluster the data in the spatial and temporal dimensions. The nodes are combined to form a globally consistent representation. Then, a spatial reconstruction decoding head is used to map the non-uniformly distributed node representations onto a pre-defined regular grid, reconstructing a continuous scalar field of parameters such as temperature, humidity, oxygen, carbon dioxide, and VOCs, and masking the grid outside the chamber. Based on this, the difference and first-order spatial gradient vector at each parameter grid are calculated, and a multi-scale gradient representation is constructed through upsampling, downsampling, and feature fusion. At the same time, the grid-level confidence is estimated based on the attention weight distribution, reconstruction residual, and model integration variance and added as a quality weight. Finally, the output is an environmental gradient map containing multi-parameter gradient vectors, gradient magnitude, direction information, and quality weights.
[0057] Specifically, this implementation takes the spatiotemporally aligned data packet output in step S1 as input, converts each record into a sequence token and adds spatial and temporal location codes, constructs adjacency relationships and relative position biases based on the spatial distance between sensors and existing ventilation and airflow topology, completes information interaction and global consistency aggregation in a unified representation space through cross-modal attention and spatiotemporal self-attention, and maps the non-uniformly distributed node representations to a preset rule grid to form a continuous scalar field of parameters such as temperature, humidity, oxygen, carbon dioxide, and VOCs through a spatial reconstruction decoding head, while calculating the first-order spatial gradient, multi-scale gradient representation, and grid-level confidence and outputting an environmental gradient map; to make the key calculation process clear and compact, attention fusion, grid reconstruction, and gradient estimation are expressed using simplified formulas, wherein cross-modal attention adopts a single-head attention form with additive relative position bias, and the information flow is determined by the similarity of token pairs and geometric topology, specifically:
[0058] ;
[0059] in For from token To token Attention weights Indicating in the index Dimensional normalization and Tokens and Embedded vector, For embedded dimensions, The relative position offset scalar is obtained by mapping the Euclidean distance between sensors, the relative azimuth angle, and the ventilation connectivity. This represents the total number of tokens in the current window. The merged token representation;
[0060] The merged token representation is mapped to rule grid points through the parameter decoding head. The continuous field values of each physicochemical parameter were obtained, and weighted normalization interpolation based on radial basis kernels was used:
[0061] ;
[0062] in For parameters At grid points The reconstruction scalar value at that location, These refer to temperature, humidity, oxygen, carbon dioxide, and volatile organic compounds, respectively. For tokens The corresponding sensor's position in the warehouse coordinate system. To be Projection to parameters Scalar output after the channel For bandwidth The radial basis kernel function is preferably a Gaussian kernel. The Euclidean norm is used; first-order spatial gradients of each parameter field are calculated on the regular lattice to characterize the intensity and direction of local changes, using a three-dimensional central difference approximation.
[0063] ;
[0064] in For parameters exist The first-order spatial gradient vector at that point, and They are respectively exist Adjacent grid points in the positive and negative directions of the axis, The spacing of the regular grid along the three axes;
[0065] To support robust decision-making and uncertainty management, this implementation estimates the grid-level confidence level for each grid point and parameter channel, and integrates three types of evidence: attention distribution entropy, reconstruction residuals, and model ensemble variance, using linear summarization.
[0066] ;
[0067] in For grid In parameters On quality weight, To aggregate local observations The reconstructed residual scalar, To correspond to the normalized scale of the residuals, To aggregate to The attention distribution entropy of the neighborhood. For model integration The variance calculated above, To normalize the variance of the integrated sample, and These are the weighting coefficients for the three types of evidence;
[0068] By upsampling, downsampling, and feature fusion of the reconstructed field and gradient map at different spatial scales, multi-scale gradient magnitude and direction representations are obtained. A mask is applied to the grid positions outside the geometric boundaries of the chamber to avoid external interference. The final output consists of a multi-parameter gradient vector, gradient magnitude and direction information, and... The resulting environmental gradient map is used for subsequent potential field construction and trajectory inference.
[0069] In this embodiment, the identification of specific environmental features related to pest activity specifically involves: aligning the environmental gradient map with the original multimodal real-time detection data within the same spatial grid and time window; extracting and normalizing features such as temperature, humidity, oxygen, carbon dioxide, and VOCs, as well as their first-order gradient, second-order difference, and gradient direction relationships; obtaining environmental suitability and environmental pressure based on weights determined through training; constructing a potential function field under value and monotonic constraints; and deriving the force field based on this field; and analyzing the local extrema of the potential field and the streamline density of the force field, under the conditions of satisfying suitability and pressure thresholds. Connected regions with local minima of the potential function are identified as attraction sources, and local maxima are identified as repulsion sources. The center line of a connected region where streamlines cross a density reaching a threshold is identified as a migration channel, and saddle points with alternating upward and downward trends are identified. At the same time, trap triggering, abnormal VOCs increments, and sudden temperature and humidity changes are mapped as observational evidence. The confidence of candidate regions is weighted and updated exponentially. Stable target regions are retained after testing the spatial overlap, centroid displacement, and potential value stability of continuous time windows. If any target region passes the consistency test, it is determined that there are specific environmental characteristics related to pest activity.
[0070] The analysis of the environmental attraction and repulsion forces experienced by pests in the gradient map is as follows: In the gradient map, the constructed potential function field is regarded as a scalar potential, and the direction of force is defined as the steepest direction of the potential function's descent. The intensity of the force is positively correlated with the spatial rate of change of the potential function. When configuring the airflow sensor, its estimated external flow field is superimposed as an additional force component. When the force vector points to the identified local minimum connected region of the potential function, it is defined as the environmental attraction force to that region. When the force vector deviates from the local maximum connected region of the potential function, it is defined as the environmental repulsion force from that region. The strength of attraction and repulsion varies with the gradient amplitude of the potential function and is jointly affected by the superimposed components of the external flow field.
[0071] Specifically, in this embodiment, the environmental gradient map output in step S2 is aligned with the original multimodal detection data on the same spatial grid and time window, and a temperature-inclusive graph is constructed for each grid point. ,humidity ,oxygen ,carbon dioxide With volatile organic compounds The feature set relating its first-order gradient, second-order difference, and gradient direction is normalized and then used to obtain the environmental suitability through weights determined during the training phase. Environmental pressure scalar representation;
[0072] in The grid position in the warehouse coordinate system. The larger the value, the more favorable it is for pest activity. The larger the value, the less favorable it is for pest activity;
[0073] A potential function field is constructed under the constraints of value selection and monotonicity to simultaneously reflect the environmental driving force of "seeking benefits and avoiding harm". The following approach is adopted: ;
[0074] in For grid The potential function value at that point, and As a weighting coefficient for environmental stress and environmental suitability, to ensure Increase rise and Increase reduce;
[0075] The force field is derived from the negative gradient of the potential function, allowing for the superposition of external airflow effects. The following method is used:
[0076] ;
[0077] in This represents the equivalent force vector exerted by the environment on the pest. For spatial coordinates Operator for finding gradient The external flow field vector is estimated by airflow sensors or ventilation conditions. This is the weighting coefficient for the external flow field, taken when no airflow sensor is configured. ;
[0078] Combination and The spatial distribution, in this embodiment, under the conditions of suitability and pressure threshold, is... Local minimum connected regions are identified as attracting sources, and local maximum connected regions are identified as repulsive sources. Streamline tracing and density analysis are performed. Centerlines of connected regions with densities exceeding a threshold are identified as migration channels. Key points exhibiting alternating upward and downward trends in different main directions are identified as saddle points. To improve the robustness of target identification, this implementation maps trap triggering, VOCs increment anomalies, and sudden temperature and humidity changes as observational evidence and performs weighted and exponential sliding updates on the confidence levels of candidate regions.
[0079] ;
[0080] in The confidence level of the candidate region within the current time window. The confidence level for the previous time window. For smoothing coefficients, The comprehensive evidence score is calculated by normalizing the trapping trigger intensity, VOCs abnormality score, and temperature and humidity mutation score according to source weights.
[0081] Within a continuous time window, a consistency check is performed based on spatial overlap, centroid displacement, and potential stability, retaining only stable target regions that pass the check; in the force interpretation, when The direction points to the identified The local minimum connectivity region is defined as the environmental attraction of that region, when The direction deviates from the identified The term "locally maximally connected region" is defined as the repulsive force emanating from the environment within that region; the strength of attraction and repulsion varies with... Size changes and are affected The superposition of factors means that if any attraction source, repulsion source, migration route, or saddle point that passes the consistency test exists, it is determined that there are specific environmental characteristics related to pest activity.
[0082] In this embodiment, the simulated pest behavior response specifically involves: encoding the environmental gradient map, force field, and target environmental features as conditional inputs; generating initial seed points at the center of the attraction source, the entrance of the migration channel, the most recent trapping trigger, and the location of VOCs anomalies, assigning them initial direction and velocity; loading a trained generative diffusion model to perform force-guided diffusion sampling at a fixed prediction duration and time step, generating a trajectory sample set under boundary and dynamic constraints; subsequently, using particle filtering to fuse the samples with current observational evidence and resample; scoring the samples according to observational consistency, physical feasibility, and model confidence, and selecting the highest-scoring trajectory as the representative trajectory; constructing a direction histogram for the direction sequence of the representative trajectory within the prediction duration and taking the main peak as the migration direction; taking the median of the unit time displacement sequence as the velocity estimate; simultaneously collecting all individual trajectory location points within the prediction duration for fixed-radius density clustering, identifying high-density connected regions and using their centroids as potential aggregation locations, outputting the corresponding aggregation radius and individual count, and combining sample dispersion, model internal confidence, and observational consistency to give the confidence level of direction, velocity, and aggregation location;
[0083] The target environmental features include attraction sources, repulsion sources, migration routes, and saddle points;
[0084] Specifically, in this implementation, the environmental gradient map output in step S2, the force field obtained in step S3, and the identified attraction sources, repulsion sources, migration channels, and saddle points are encoded as conditional inputs. Initial seed points are first generated at the center of the attraction source, the entrance to the migration channel, the most recent trapping trigger location, and the VOCs anomaly location. The number of seed points can be configured as follows: indivual;
[0085] in The initial number of seed points;
[0086] The initial direction is assigned based on the local principal force direction, and the initial velocity is assigned by a weighted average of the force intensity and the empirical velocity upper limit. The prediction duration is set to... There are 1 time steps and the duration of each step is 1 ;
[0087] in To predict the number of steps, To predict the step size;
[0088] Simultaneously, geometric and dynamic constraints are applied to the chamber to limit the maximum velocity and maximum acceleration, denoted as follows: and After loading the offline-trained conditional diffusion model, force-guided sampling is performed. In each diffusion step, the sample state is projected back into the feasible region to ensure physical feasibility and avoid out-of-bounds errors. The core update is written as:
[0089] ;
[0090] in For the first Each trajectory sample in the diffusion step Spatial position vector, For sample index, For diffusion step index and The total number of diffusion steps, For parameters Characterized diffusion denoising network, The condition set includes the environmental gradient map, the force field, and the characteristics of the target environment. The step-size related noise scale, For force-guided gain, The environmental force field obtained in step S3, To reach the feasible region The projection operator and Constrained by the cargo box boundaries and the maximum speed limit With the upper limit of acceleration Equal constraints are defined together;
[0091] After obtaining a set of trajectory samples covering the entire prediction window, to fuse with online observation evidence and enhance robustness, particle filtering is used to weight and resample the samples, with the weights updated as follows:
[0092] ;
[0093] in For the first Each sample in the observation time index Unnormalized weights For its previous weight, The set of observational evidence types includes trap-triggered events, abnormal VOC increases, and abrupt changes in temperature and humidity. For the first Each sample in time The predicted location, For type In time The observation, For type The distance or residual metric of the match. For type The noise scale;
[0094] After normalizing the weights and resampling, the samples are comprehensively scored based on observational consistency, physical feasibility, and internal model confidence. The highest-scoring sample is selected as the representative trajectory, and its discrete position sequence is denoted as... Then, the migration direction and velocity are estimated from this representative trajectory. The direction is given by the histogram of the main peak direction, and the velocity is taken as the median displacement per unit time.
[0095] ;
[0096] in The predicted main direction of migration, The set of central angles of the discrete direction set. To count the directions from the histogram obtained by statistically analyzing the azimuth angles of adjacent trajectory segments, For speed estimation, It is the Euclidean norm;
[0097] Finally, discrete location points of all trajectory samples collected within the prediction window are subjected to fixed-radius density clustering to identify potential clustering regions. The clustering parameters include the search radius. With minimum number of points threshold ;
[0098] in This represents the maximum neighborhood radius between a point and its core point within the same cluster. This represents the minimum number of samples required to form a cluster;
[0099] The centroid of each connected high-density region is used as a potential clustering location. The clustering radius and individual count of each region are output to quantify the spatial scale and size. To provide confidence levels for direction, velocity, and clustering location, this implementation constructs a unified confidence index that integrates evidence consistency, internal model uncertainty, and sample dispersion.
[0100] ;
[0101] in For the final confidence level, The observational consistency score is given by the degree of spatiotemporal overlap between the representative trajectory and the evidence. The internal confidence level of the model can be obtained by normalizing the ensemble variance or the lower bound of the log-likelihood. The normalized dispersion index for the sample set reflects the uncertainty of the trajectory samples. and The weighting coefficients are fixed during the training or calibration phase to ensure consistency in online evaluation.
[0102] In this embodiment, the calculation and output of the corresponding risk level specifically involves: aligning target environmental characteristics, force fields, and representative trajectories within the same spatial grid and assessment time window, while retaining grid quality weights and trajectory confidence weights; dividing the assessment area according to a fixed resolution and setting a sliding assessment window and a historical comparison window; statistically analyzing trajectory points around the degree of occurrence and standardizing them by area to form individual density; combining cluster counts and radius to form cluster intensity; and calculating the change amplitude with the historical comparison window to obtain the growth trend; statistically analyzing the inflow along identified migration channels around the diffusion risk and standardizing it by combining channel length, force field intensity within the channel, and the difficulty coefficient of boundary constraints; and so on. The estimated arrival time is estimated based on the representative trajectory velocity and channel geometric distance and discretized into time period categories. Environmental suitability, environmental pressure, and stress intensity within the region are weighted and averaged according to grid quality weights. Then, individual density, aggregation intensity, growth trend, inflow, estimated arrival time classification, environmental suitability, environmental pressure, and stress intensity are weighted and summarized into a single comprehensive risk index according to preset weights. An uncertainty penalty term consisting of trajectory dispersion and model internal confidence indicators is deducted according to preset weights. Finally, based on three thresholds determined and fixed during the training phase, the comprehensive risk index is divided into four risk levels, thus obtaining a regional risk assessment.
[0103] Specifically, this implementation aligns target environmental characteristics, force fields, and representative trajectories within a unified spatial grid and assessment time window. It divides the assessment area at a fixed resolution and sets a sliding assessment window and a historical comparison window. Within each assessment area, it calculates indicators based on three main lines: occurrence degree, diffusion risk, and environmental conditions, and merges them into a single comprehensive risk index to achieve tiered early warning. First, it measures the occurrence degree, counts the number of trajectory points within the area, and standardizes the density by area to obtain the individual density. ;
[0104] in For the assessment area Individual density, To assess the area falling within the time window The number of trajectory points, For the region The geometric area;
[0105] Simultaneously, the clustering intensity within the region is measured using clusters obtained from fixed-radius density clustering, employing:
[0106] ;
[0107] in For aggregation strength, For the region Inner cluster set, For clusters Individual count, For clusters The equivalent radius, To convert the count and scale into monotonic functions of intensity, To prevent tiny constants with a denominator of zero;
[0108] To reflect the recent growth trend relative to historical levels, the following method is used: ;
[0109] in As a growth trend, For historical comparison window area Average individual density, It is the stabilization constant;
[0110] Regarding diffusion risk, the inflow is statistically analyzed along identified migration channels and standardized by combining channel geometry and stress conditions, using the following method: and ;
[0111] in For channel Standardized entry traffic, The evaluation unit is the number of trajectory segments entering the area. For channel geometric length, For channel The average value of the internal force field intensity along the line. To limit the difficulty level by setting boundaries, The stabilization constant is For estimated arrival time, This represents the geometric distance from the trajectory to the end of the channel or the target area. The representative trajectory velocity estimated in step S4;
[0112] The expected arrival time is discretized into time periods to form a risk contribution score, using the following method:
[0113] ;
[0114] in For channel Time-segmented scoring Number of time segments For the first A time interval, This represents the risk weight for that interval. It is an indicator function;
[0115] Regarding environmental conditions, a weighted average of environmental suitability, environmental pressure, and stress intensity is calculated using grid quality weights, and the following method is adopted: ;
[0116] in For the region The weighted average environmental indicators For the region The grid set within, For grid Quality weight, For grid The index values on the above Indicates environmental suitability. Indicating environmental pressure, Indicates the strength of the force and The force vector obtained in step S3, It is the Euclidean norm;
[0117] The above indicators are combined into a single comprehensive risk index, and an uncertainty penalty is introduced. The following approach is adopted:
[0118] ;
[0119] in For the region The comprehensive risk index, In order to cooperate with the region The collection of intersecting migration routes, The fusion weights for each indicator are determined and calibrated during the training phase. They are respectively regions The weighted fitness, pressure and stress intensity, This is the uncertainty penalty coefficient. This is an uncertainty penalty term;
[0120] The uncertainty penalty term consists of the trajectory dispersion and the model's internal confidence, and adopts the following approach:
[0121] ;
[0122] in and As a penalty weight, For the region Normalized dispersion of the inner trajectory samples, The internal confidence level is obtained by normalizing the model integration variance or log-likelihood lower bound.
[0123] Finally, based on the three thresholds determined and solidified during the training phase, the comprehensive risk index is divided into four levels, using:
[0124] ;
[0125] in For the region The risk level, This is the threshold for grading;
[0126] when Real-time early warning signals are generated and pushed to the prevention and control strategy optimization module.
[0127] in The minimum risk level required to trigger an alert.
[0128] In this embodiment, the generation or optimization of the targeted strategy specifically involves: aligning early warnings, risk lists, environmental gradients, force fields, representative trajectories, and aggregation locations within the same spatial grid and planning time window, selecting higher-risk areas as targets; setting planning duration, execution step size, and resource budget to maximize the reduction of overall risk, and imposing constraints such as safety compliance, equipment, manpower, inventory, operation time window, fans, temperature and humidity control start / stop times, minimum spacing of attractants, and boundary setback distance; generating candidate solutions based on an action library including attractant deployment, adjustment, zoned ventilation, temperature and humidity control, fixed-point application, differentiated application, and parameter templates, with high-risk areas including... The strategy involves attracting animals, ventilation, humidity control, and targeted pesticide application. Higher-risk areas include attracting animals, ventilation, and humidity control. The space revolves around potential gathering points and extends along migration routes, with ventilation directed in the opposite direction of the dominant force. Integer linear programming is used to optimally determine actions and their spatiotemporal parameters under constraints. After solving, conflict and compliance checks are performed, and the solutions are resolved according to the priority order of "pesticide application > ventilation > attracting animals." The strategy is mapped to forces, and suitability adjustments are made through forward-looking simulations. If the risk in the target area does not decrease to medium risk or below, a single optimization is performed. The final output includes the action type, location, quantity, intensity, duration, execution sequence, expected risk reduction, and validity period of the targeted strategy, which is then distributed and archived.
[0129] Specifically, this implementation aligns the early warning list, comprehensive risk index, environmental gradient and force field, representative trajectory and potential clustering location within the same spatial grid and planning time window. First, it determines the target area set to be intervened and constructs an integer linear programming problem constrained by resources and operations to automatically generate a targeted strategy with action type, location, intensity, and temporal parameters. Then, based on the risk level threshold, it selects target areas, defining the target set as follows: ;
[0130] in For the entire set of assessment areas, For a certain area, The regional risk level obtained in step S5, To select the level thresholds for higher and higher-risk areas;
[0131] For each Candidate action elements are generated from the action library and mapped to discrete optional templates. This includes types such as attractant deployment / adjustment, zoned ventilation, temperature and humidity control, fixed-point application and differentiated application, and in regional... The set of candidate locations is given within the neighborhood along the migration route. The planning time axis is discretized into a set of time slots. ; in binary variables Indicates in time slot Is it in position? Execution action type Given a discrete intensity template (intensity discreteness is already reflected in the candidate templates), and with the objective of maximizing the reduction of overall risk while also considering cost penalties, the objective function is established as follows:
[0132] ;
[0133] in For the region The risk weights can be obtained by normalizing the comprehensive risk index in step S5. Action type The basic effective coefficient, For the action in position Scene adaptation efficiency These are the region-specific location confidence weighting coefficients obtained by aggregating raster quality weights. To perform the action At position The unit cost or resource consumption This is a cost trade-off coefficient;
[0134] And key constraints are imposed to ensure feasibility and compliance, including resource budgets and capacity limits, as well as minimum spatial spacing constraints, such as:
[0135] when ;
[0136] in This refers to the total budget or resource cap. Action type The concurrent device / human resources capacity in any given time slot This represents the Euclidean distance between locations. For type Minimum spacing between installations;
[0137] The ventilation action is specified to be in the opposite direction to the main force direction in order to suppress diffusion; the direction vector is set as follows:
[0138] ;
[0139] in For position The direction of ventilation. To normalize a non-zero vector to a unit direction, For position surrounding neighborhood Upper force vector On average, The number of neighboring raster cells;
[0140] To avoid unnecessary start-up, shutdown, and operational conflicts, conflict and compliance checks are performed after the solution is obtained. A priority order of "chemical application > ventilation attractor" is adopted to selectively retain and cascade conflicting actions at the same location and time slot, while simultaneously satisfying constraints such as safe backoff distance, operational time window, and equipment start-up / shutdown frequency (the time window can be set by...). (For time slots that are not allowed, they are fixed); the obtained preliminary strategy is mapped to local modulation of environmental suitability and force field to conduct look-ahead simulation; based on the strategy influence kernel, the updated regional risk is assessed; and the risk after the strategy is calculated as follows:
[0141] ;
[0142] in The region obtained in step S5 The initial comprehensive risk index, To predict risks after implementing policies, In the region Caused by action type At position The resulting unit risk reduction coefficient has incorporated factors such as strength template, radius of action, and timeliness reduction into the coefficient.
[0143] If it exists make The risk level has not yet dropped to medium or below, for example, above the threshold. Then, after updating the environment and available resources, a re-optimization solution is triggered, and the above simulation evaluation is repeated; finally, a list of target strategies after verification and necessary re-optimization is output, including action types. Execution location Quantity and intensity templates, duration and start / end time slots Ventilation direction Expected risk decline Include information such as validity period, and issue and archive the documents.
[0144] In this embodiment, a biosensor identification and prediction system includes:
[0145] Data acquisition and preprocessing module: Receives multimodal real-time detection data from multiple biosensors, which are used to monitor multiple specific physical and chemical parameters in the storage environment, and performs preprocessing operations on the multimodal detection data;
[0146] Environmental gradient map construction module: The preprocessed detection data is processed using a multimodal fusion Transformers model to identify and quantify the differences in multidimensional physical and chemical parameters at different spatial locations within the storage environment, and to generate an environmental gradient map that reflects the spatial gradient distribution.
[0147] Target Feature Recognition and Gradient Analysis Module: Based on the gradient map output by the multimodal fusion Transformers model and the preprocessed detection data, it identifies whether there are specific environmental features related to pest activity and analyzes the environmental attraction and repulsion forces experienced by pests in the gradient map.
[0148] Individual migration path tracking and prediction module: When the target feature identification and gradient analysis steps identify target features related to pest activity and calculate environmental attraction and repulsion, based on the generative diffusion model, the module uses the environmental gradient map and the analyzed environmental attraction and repulsion to simulate the pest's behavioral response, track its individual activity trajectory, and predict its migration direction, speed, and potential aggregation location in the future.
[0149] Risk level assessment and early warning module: Based on the specific environmental features identified in the target feature identification and gradient analysis step, the migration trajectory tracked in the individual migration path tracking and prediction step, and the predicted aggregation location, it assesses the occurrence degree and spread risk of pests in the storage environment, calculates and outputs the corresponding risk level; and generates a real-time early warning signal when the risk level reaches a preset threshold.
[0150] Prevention and control strategy optimization module: When the real-time early warning signal is received or the risk level assessment result is obtained, a targeted prevention and control intervention strategy is generated or optimized based on the environmental gradient map, the tracked individual activity trajectory and the predicted aggregation location information.
[0151] The above description is only a preferred embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any equivalent substitutions or modifications made by those skilled in the art within the scope of the technology disclosed in the present invention, based on the technical solution and inventive concept of the present invention, should be covered within the scope of protection of the present invention.
Claims
1. A method for biosensor identification and prediction based on deep learning, characterized in that, Includes the following steps: S1. Receive multimodal real-time detection data from multiple biosensors, wherein the biosensors are used to monitor multiple specific physical and chemical parameters in the storage environment, and preprocess the multimodal detection data to obtain an initial input dataset; S2. The preprocessed initial input dataset is processed using a multimodal fusion Transformer model to identify and quantify the differences in multidimensional physical and chemical parameters at different spatial locations within the storage environment, thereby generating an environmental gradient map that reflects the spatial gradient distribution. S3. Based on the environmental gradient map and the initial input data, identify whether there are specific environmental features related to pest activity, and analyze the environmental attraction and repulsion forces experienced by the pest in the gradient map. S4. When specific environmental features related to pest activity are identified and environmental attraction and repulsion are calculated, based on the generative diffusion model, the environmental gradient map and the analyzed environmental attraction and repulsion are used to simulate the pest's behavioral response, track its individual activity trajectory, and predict its migration direction, speed and potential aggregation location in the future. S5. Based on the identified specific environmental characteristics, individual activity trajectories, migration directions, and predicted aggregation locations related to pest activities, assess the occurrence and spread risk of pests in the storage environment, calculate and output the corresponding risk level, and generate a real-time early warning signal when the risk level reaches a preset threshold. S6. When the real-time early warning signal is received or the risk level assessment result is obtained, a targeted strategy for prevention and intervention in the storage environment is generated or optimized based on the environmental gradient map, the tracked individual activity trajectory and the predicted aggregation location information.
2. The method for biosensor identification and prediction based on deep learning according to claim 1, characterized in that: The multimodal real-time detection data includes temperature, humidity, gas composition, and volatile organic compounds; The preprocessing specifically includes: registering and spatially calibrating multiple biosensors to record unique identifiers, three-dimensional positions, and modal types; receiving data in real time under a unified reference clock and adding a global timestamp to each record; performing time synchronization and resampling on data from different modalities, aligning each modal sequence to a preset sampling interval; conducting anomaly detection and data cleaning, removing noise points and distorted samples based on physical boundaries, statistical thresholds, and neighborhood consistency; implementing baseline drift correction and cross-sensitivity compensation, compensating for VOCs channel drift based on a zero-air baseline and correcting the response in conjunction with temperature and humidity; and performing denoising filtering, sequentially using low-pass filtering and wavelet thresholding to suppress high-frequency noise. Spatiotemporal neighborhood weighted imputation is performed on missing and discontinuous data to maintain sequence continuity; features such as amplitude, mean, standard deviation, slope and integral area are extracted within a sliding time window; Multimodal features are normalized and scaled; and spatiotemporal alignment and sample packaging are performed according to a preset sliding time window to form an initial input dataset containing modality identifiers, spatial coordinates, time indices and quality weights.
3. The method for biosensor identification and prediction based on deep learning according to claim 1, characterized in that: The environmental gradient map is specifically described as follows: the initial input dataset is grouped and tensed into sequence tokens according to sensing modality, spatial coordinates and time index. Each modality obtains a unified dimensional representation through a feature encoder and is further encoded with spatial and temporal location codes generated by three-dimensional coordinates and timestamps. Based on the spatial distance between sensors and the known ventilation and airflow topology, adjacency relationships are constructed, and relative positional biases and neighborhood weights are calculated. These tokens are then input into a multimodal fusion Transformer to perform cross-modal attention, enabling information interaction and adaptive weight fusion. Subsequently, spatiotemporal self-attention propagates and aggregates in the spatial and temporal dimensions to form globally consistent node representations. Then, a spatial reconstruction decoding head is used to map the non-uniformly distributed node representations onto a pre-defined regular grid, reconstructing continuous scalar fields of parameters such as temperature, humidity, oxygen, carbon dioxide, and VOCs, and masking the external grid. Based on this, the differences and first-order spatial gradient vectors at each parameter grid are calculated, and multi-scale gradient representations are constructed through upsampling, downsampling, and feature fusion. At the same time, grid-level confidence is estimated based on attention weight distribution, reconstruction residuals, and model ensemble variance and added as quality weights. Finally, an environmental gradient map containing multi-parameter gradient vectors, gradient magnitudes, direction information, and quality weights is output.
4. The method for biosensor identification and prediction based on deep learning according to claim 1, characterized in that: The specific method for identifying specific environmental features related to pest activity is as follows: align the environmental gradient map with the original multimodal real-time detection data in the same spatial grid and time window, extract features such as temperature, humidity, oxygen, carbon dioxide and VOCs, as well as their first-order gradient, second-order difference and gradient direction relationship, and normalize them. Based on the weights determined during training, environmental suitability and environmental pressure are obtained respectively. Under the constraints of value selection and monotonicity, a potential function field is constructed and the force field is derived accordingly. Through the analysis of local extrema of the potential field and the density of the force streamlines, under the conditions of satisfying the suitability and pressure thresholds, the connected regions with local minima of the potential function are judged as attraction sources and the local maxima are judged as repulsion sources. The center line of the connected region where the streamline density reaches the threshold is judged as the migration channel, and saddle points with alternating upward and downward trends are identified. At the same time, the triggering of the trap, the abnormal increase of VOCs and the sudden change of temperature and humidity are mapped as observational evidence. The confidence of the candidate region is weighted and updated exponentially. The stable target region is retained after the spatial overlap of the continuous time window, the displacement of the centroid and the stability of the potential value are tested. If any target area passes the consistency test, it is determined that there are specific environmental features related to pest activity. The analysis of the environmental attraction and repulsion forces experienced by pests in the gradient map is as follows: In the gradient map, the constructed potential function field is considered a scalar potential, and the direction of the force is defined as the steepest descent direction of the potential function. The intensity of the force is positively correlated with the spatial rate of change of the potential function. When configuring airflow sensors, their estimated external flow field is superimposed as an additional force component. When the force vector points to an identified local minimum connected region of the potential function, it is defined as an environmental attraction force to that region. When the force vector deviates from a local maximum connected region of the potential function, it is defined as an environmental repulsion force from that region. The strength of attraction and repulsion varies with the gradient magnitude of the potential function and is also affected by the superposition components of the external flow field.
5. The method for biosensor identification and prediction based on deep learning according to claim 4, characterized in that: The simulated pest behavior response is specifically as follows: Environmental gradient maps, force fields, and target environmental features are encoded as conditional inputs. Initial seed points are generated at the center of the attraction source, the entrance to the migration channel, the most recent trapping trigger, and the location of VOCs anomalies, assigning them initial direction and velocity. A trained generative diffusion model is loaded and force-guided diffusion sampling is performed at fixed prediction durations and time steps, generating a trajectory sample set under boundary and dynamic constraints. Subsequently, particle filtering is used to fuse the samples with current observational evidence and resample them. The samples are scored according to observational consistency, physical feasibility, and model confidence, and the highest-scoring sample is selected as the representative trajectory. Within the prediction duration, a direction histogram is constructed for the direction sequence of the representative trajectory, and the main peak is taken as the migration direction. The median of the unit-time displacement sequence is taken as the velocity estimate. Simultaneously, all individual trajectory location points within the prediction duration are collected and subjected to fixed-radius density clustering. High-density connected regions are identified, and their centroids are used as potential aggregation locations. The corresponding aggregation radius and individual count are output, and the confidence levels of direction, velocity, and aggregation location are given by combining sample dispersion, model internal confidence, and observational consistency. The target environmental features include attraction sources, repulsion sources, migration routes, and saddle points.
6. The method for biosensor identification and prediction based on deep learning according to claim 5, characterized in that: The calculation and output of the corresponding risk level are specifically as follows: within the same spatial grid and evaluation time window, the target environmental characteristics, force field and representative trajectory data are aligned and the grid quality weight and trajectory confidence weight are retained. The evaluation area is divided according to a fixed resolution and a sliding evaluation window and a historical comparison window are set. Individual density is formed by statistically tracing the occurrence degree around the points and standardizing them by area. Cluster intensity is formed by combining cluster count and radius, and the growth trend is obtained by calculating the change range with historical comparison windows. The study standardizes the inflow of population along identified migration channels to assess diffusion risk by combining channel length, force field strength within the channel, and difficulty coefficients of boundary constraints. Simultaneously, it estimates the estimated arrival time based on representative trajectory speeds and channel geometric distances, and discretizes it into time-segment categories. For environmental conditions, it weights and averages regional environmental suitability, environmental pressure, and force intensity according to grid quality weights. Then, it weights and summarizes indicators such as individual density, aggregation intensity, growth trend, inflow, estimated arrival time classification, environmental suitability, environmental pressure, and force intensity according to preset weights into a single comprehensive risk index. An uncertainty penalty term, composed of trajectory dispersion and model internal confidence indicators, is deducted according to preset weights. Finally, based on three thresholds determined and solidified during the training phase, the comprehensive risk index is divided into four risk levels, thus obtaining a regional risk assessment.
7. The method for biosensor identification and prediction based on deep learning according to claim 6, characterized in that: The specific strategy for generating or optimizing the targeted approach is as follows: aligning early warnings, risk lists, environmental gradients, force fields, representative trajectories, and cluster locations within the same spatial grid and planning time window, and selecting higher-risk areas as targets; The planning timeframe, execution step size, and resource budget are set to maximize the reduction of overall risk. Constraints are imposed on safety compliance, equipment, manpower, inventory, operation time window, fans, temperature and humidity control start-up and shutdown frequency, minimum spacing of attractants, and boundary setback distance. Based on the action library, including attractant deployment, adjustment, zoned ventilation, temperature and humidity control, fixed-point application, differentiated application, and parameter templates, candidate solutions are generated. High-risk scenarios include attractant + ventilation + humidity control + fixed-point application, while higher-risk scenarios include attractant + ventilation + humidity control. The space revolves around the potential aggregation point and along... The migration route is set up, and the ventilation direction is the opposite of the main force direction. Integer linear programming is used to optimally determine the actions and their spatiotemporal parameters under constraints. After the solution is obtained, conflict and compliance verification is performed, and the conflicts are resolved according to the priority of "drug application > ventilation > trap". The strategy is mapped to the force and suitability adjustment and prospective simulation is carried out. If the risk in the target area does not drop to medium risk or below, a single optimization is performed. The final output includes the action type, location, quantity, intensity, duration, execution sequence, expected risk reduction and validity period of the targeted strategy, which is then distributed and archived.
8. A biosensor identification and prediction system, comprising the deep learning-based biosensor identification and prediction method according to any one of claims 1 to 7, characterized in that, Includes the following modules: Data acquisition and preprocessing module: Receives multimodal real-time detection data from multiple biosensors, which are used to monitor multiple specific physical and chemical parameters in the storage environment, and performs preprocessing operations on the multimodal detection data; Environmental gradient map construction module: The preprocessed detection data is processed using a multimodal fusion Transformers model to identify and quantify the differences in multidimensional physical and chemical parameters at different spatial locations within the storage environment, and to generate an environmental gradient map that reflects the spatial gradient distribution. Target Feature Recognition and Gradient Analysis Module: Based on the gradient map output by the multimodal fusion Transformers model and the preprocessed detection data, it identifies whether there are specific environmental features related to pest activity and analyzes the environmental attraction and repulsion forces experienced by pests in the gradient map. Individual migration path tracking and prediction module: When the target feature identification and gradient analysis steps identify target features related to pest activity and calculate environmental attraction and repulsion, based on the generative diffusion model, the module uses the environmental gradient map and the analyzed environmental attraction and repulsion to simulate the pest's behavioral response, track its individual activity trajectory, and predict its migration direction, speed, and potential aggregation location in the future. Risk level assessment and early warning module: Based on the specific environmental features identified in the target feature identification and gradient analysis step, the migration trajectory tracked in the individual migration path tracking and prediction step, and the predicted aggregation location, assess the occurrence degree and spread risk of pests in the storage environment, calculate and output the corresponding risk level; And when the risk level reaches a preset threshold, a real-time warning signal is generated; Prevention and control strategy optimization module: When the real-time early warning signal is received or the risk level assessment result is obtained, a targeted prevention and control intervention strategy is generated or optimized based on the environmental gradient map, the tracked individual activity trajectory and the predicted aggregation location information.
Citation Information
Cited By
Processing characteristic monitoring and analyzing system for early indica rice for rice noodles in storage process
CN121955313A