Crop fertilizer efficiency regulation and control method and device based on time sequence spectrum and medium
By using a deep learning model based on time-series spectra, combined with a multi-output structure and feedback mechanism, the problems of dynamic monitoring and interpretability of fertilization decisions in agricultural production have been solved, achieving intelligent improvement in crop nutrient management and increased accuracy in fertilization.
Patent Information
- Application Number
- CN202511407255.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-09-29
- Publication Date
- 2025-12-23
AI Technical Summary
In current agricultural production, fertilization decisions rely on static image judgment or human experience, lacking dynamic monitoring and trend prediction of crop physiological state. This leads to over-fertilization, timing deviations, or inefficiency. Furthermore, the output of traditional deep learning models lacks interpretability and risk representation, making it difficult to gain the trust of farmers and agricultural technicians.
A crop fertilizer efficiency regulation method based on time-series spectroscopy is adopted, combined with deep learning models and feedback mechanisms, to construct a closed-loop regulation system with multiple output structures. The crop nutrient status is identified through time-series convolution and attention fusion mechanisms, realizing multi-dimensional state encoding and interpretable decision-making.
It has improved the intelligence level of crop nutrient management, enhanced the interpretability and consistency of decision-making, possessed personalized feedback optimization capabilities, and improved the accuracy and efficiency of fertilization.
Smart Images

Figure CN121189574A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the fields of precision agriculture and artificial intelligence, specifically to a method, device, and medium for regulating crop fertilizer efficiency based on time-series spectroscopy. Background Technology
[0002] Currently, fertilization decisions in agricultural production largely rely on static image analysis or manual experience rules, lacking the ability to dynamically monitor and predict crop physiological states. This easily leads to over-fertilization, timing errors, or inefficiency. Although crop diagnostic methods based on NDVI or multispectral imaging exist, most are still based on single-point static features and lack the ability to model the "spectral change-nutrient trend." Furthermore, the outputs of traditional deep learning models often lack interpretability and risk representation, making it difficult to gain the trust of farmers and agricultural technicians. Fertilization recommendations are primarily based on "whether to apply topdressing," lacking structured parameter recommendations and confidence boundary explanations, which also limits practical implementation. Summary of the Invention
[0003] To address the shortcomings of existing technologies, this invention provides a method and device for regulating crop fertilizer efficiency based on time-series spectra. It is based on the identification of nutrient status and variable fertilization decision-making based on multi-temporal changes in crop leaf spectra. Combined with deep learning models and feedback mechanisms, it constructs a closed-loop regulation system with multiple output structures, prediction confidence perception capabilities, and adaptive optimization functions, thereby improving the level of intelligent crop nutrient management.
[0004] To solve the aforementioned technical problem, the technical solution adopted by the present invention is: a method for regulating crop fertilizer efficiency based on time-series spectroscopy, comprising the following steps: S01. Construct a multi-temporal image sequence that integrates spectral changes and environmental information; S02. Introduce a deep recognition model with temporal convolution and attention fusion mechanisms. The deep recognition model includes a one-dimensional temporal convolutional layer, a backbone feature extraction module, and a multi-output task module connected in sequence. The backbone feature extraction module is composed of multiple temporal convolutional layers and a temporal attention module stacked together. The temporal convolutional layer models the trend evolution of spectral reflectance at different time points and is used to extract spectral temporal features. The temporal attention module realizes dynamic weighting of key bands. S03. Multi-temporal image sequences are transmitted to the deep recognition model. A one-dimensional temporal convolutional layer identifies spectral abrupt change points in the spectral temporal data of the multi-temporal image sequences. The identified spectral abrupt change points serve as the guiding terms of the temporal attention module, thereby giving the model sensitivity to changes in physiological state. S04. The multi-output task module is equipped with multiple parallel task decoding headers, which are used to receive data from the backbone feature extraction module and realize the current nutrient status scoring, future trend prediction, and variable fertilization suggestions. S05. Based on the uncertainty estimation mechanism, output the prediction confidence interval and band channel importance interpretation information.
[0005] Furthermore, step S01 specifically involves: periodically acquiring multi-band image sequences of specific leaf positions of crops, while simultaneously recording the acquisition time, growth period, weather conditions, and soil information corresponding to each image frame. All information is processed by tensor quantization to form a unified input, constituting time-series spectral-environment dual-modal sequence data. The time-series spectral-environment dual-modal sequence data from multiple moments form a multi-temporal image sequence.
[0006] Furthermore, the spectral abrupt change point identification method is as follows: Let the spectral time series data sequence be... , Let represent the spectral time series data at time t, where T is the total number of spectral time series data. The spectral time series data sequence is normalized, and the first derivative sequence of the spectral time series data sequence is calculated. The method for identifying abrupt changes is based on a sequence of first-order derivatives. This identification includes both magnitude and direction abrupt changes. The magnitude abrupt change determination is performed using the relevant inequality. Whether it is valid, among which The standard deviation of the first derivative sequence. The threshold is the amplitude multiple. If it holds, an amplitude abrupt change is considered to exist; if it does not hold, an amplitude abrupt change is considered not to exist. The direction abrupt change is determined by a judgment inequality. If the condition is met, a directional abrupt change is considered to exist; otherwise, no directional abrupt change is considered to exist. If an amplitude abrupt change or both amplitude and direction abrupt changes occur at a certain moment, that moment is marked as a spectral abrupt change point, and a mask vector is output. , This indicates that time t is the spectral abrupt change point. This indicates that time t is not a spectral abrupt change point.
[0007] Furthermore, spectral mutation points, serving as guiding terms for the attention mechanism of deep recognition models, endow the models with sensitivity to changes in physiological states as follows: Get the mask vector ,Will The attention mechanism of embedded deep recognition models has two embedding methods: 1. Attention weight recalibration, adjusting the mask vector Convert to a weight correction vector and recalculate the attention score vectors for all time steps of the temporal attention module. Then The normalized input is then fed into the softmax layer as the attention distribution; where This represents the original attention score vector at all times of the temporal attention module. For the recalculated attention scoring vector, It is a mutation enhancer; II. Position biasing mechanism, which adjusts the mask vector A mutation guidance vector is generated after a linear mapping layer or an embedding layer. , will mutation guide vector The updated position is obtained by weighted fusion with the original temporal position embedding of the deep recognition model. The updated position is then embedded into the encoding layer of the deep recognition model. The weighted fusion formula is as follows: Where P is the original temporal position embedding of the deep recognition model. This indicates the updated position embedding. This is a guide bias factor.
[0008] Furthermore, the current nutrient status score, future trend prediction, variable fertilization recommendations, band channel importance explanation information, and prediction confidence interval are mutually constrained. The mutual constraint logic is as follows: the current nutrient status score is a prerequisite for variable fertilization recommendations; the future trend prediction will automatically verify when it contradicts the current nutrient status score; the variable fertilization recommendations depend on the current nutrient status score being <0.7 and the future trend prediction being downward; the band channel importance explanation information is used to provide interpretability to users; and the prediction confidence interval is linked with the variable fertilization recommendations to display risk zones.
[0009] Furthermore, the consistency of the mutual constraint logic is ensured by using the edge weight matrix of the graph structure and the mutual constraint loss function during training. The implementation process is as follows: Construct a graph structure between multiple output tasks , where the set of nodes Let there be n output tasks, and let the set of edges E represent the logical dependencies between the output tasks. Each edge... Corresponding to one edge weight , border rights To represent the consistency constraint strength between two output tasks, construct an n*n sparse graph structure and set edge weights. A trainable parameter matrix that can be either fixed or dynamically learned during the training phase; The mutual constraint loss function is: , in Represents the total loss function. to This represents the loss formula corresponding to the first to nth output tasks. These represent the outputs of the i-th and j-th tasks to input x, respectively. Represents the distance metric function. This is the mutual constraint strength adjustment coefficient. For border rights.
[0010] Furthermore, there are two ways to implement the uncertainty estimation mechanism. One is the MC Dropout mechanism, which keeps Dropout active during the inference phase of the deep recognition model, allowing the deep recognition model to output uncertainly. It also calculates the mean and standard deviation of multiple results to construct a confidence interval, and the predicted score lies within the interval. Inside, among which To output the average value multiple times, To output the standard deviation, One is to represent the confidence coefficient; the other is to use a Bayesian neural network or deep ensemble to construct multiple weights to initialize different models, and to take the statistical distribution of the output of each model. The output interval reflects the degree of uncertainty and consistency between the models.
[0011] Furthermore, it also includes step S06, feedback and self-learning closed-loop optimization, generating a field memory vector for each plot, which stores the environmental, crop, and historical response features of the plot. After harvest, the actual yield, NDVI, and fertilization execution records of the plot are collected to form feedback pairs. An adaptive loss reweighting mechanism is used to update the model weights to achieve local adaptive optimization across cycles and crops.
[0012] The present invention also discloses a crop fertilizer efficiency regulation device based on time-series spectroscopy, comprising a processor and a memory storing program instructions, wherein the processor is configured to execute the crop fertilizer efficiency regulation method based on time-series spectroscopy as described above when running the program instructions.
[0013] The present invention also discloses a storage medium storing program instructions, which, when executed, perform the crop fertilizer efficiency regulation method based on time-series spectrum as described above.
[0014] The beneficial effects of this invention are as follows: 1. The deep recognition model has deep collaborative features, constructs an image perception backbone that combines temporal convolution and channel attention, integrates multimodal input and contextual information, and realizes multidimensional crop state encoding.
[0015] 2. Enhanced decision interpretability: Output auxiliary indicators such as band weighting charts, confidence intervals, and trend classifications to improve farmers' and platform's confidence in using the platform.
[0016] 3. Strong consistency of output structure logic: The five tasks have logical constraints based on the task graph structure, ensuring prediction stability; 4. Mutation point detection mechanism: Activate the model attention mechanism by using the spectral derivative change points in the time series to enhance the system's response to abnormal states; 5. Personalized feedback optimization path: Based on field-level memory vectors and local adaptation mechanisms, it supports long-term evolution and regional generalization. Attached Figure Description
[0017] Figure 1 This is a flowchart of the method described in Example 1; Figure 2 This is a schematic diagram of the depth recognition module; Figure 3 This is a schematic diagram of the device described in Example 1. Detailed Implementation
[0018] The present invention will be further described below with reference to the accompanying drawings and specific embodiments.
[0019] Example 1 This embodiment discloses a method for regulating crop fertilizer efficiency based on time-series spectroscopy, such as... Figure 1 As shown, it includes the following steps: S01. Construct a multi-temporal image sequence that integrates spectral changes and environmental information.
[0020] S02, Introduce a deep recognition model with temporal convolution and attention fusion mechanisms, such as Figure 2 As shown, the deep recognition model includes a one-dimensional temporal convolutional layer, a backbone feature extraction module, and a multi-output task module connected in sequence. The backbone feature extraction module is composed of multiple temporal convolutional layers and a temporal attention module stacked together. The temporal convolutional layer models the trend evolution of spectral reflectance at different time points and is used to extract spectral temporal features. The temporal attention module realizes dynamic weighting of key bands.
[0021] exist Figure 2 In this framework, the bidirectional RNN serves as a supplementary modeling module for time series data. It performs bidirectional dependency modeling of spectral temporal features, further capturing cross-stage contextual trends on top of the front-end temporal convolution and attention modules. Its main functions are: enhancing the robustness of trend prediction by avoiding reliance on local abrupt changes while ignoring long-term trends; supplementing global temporal features by complementing the convolutional features of the backbone and improving prediction stability; and providing classification criteria for auxiliary outputs as an auxiliary feature extraction pathway for nutrient trend classification and state classification. Softmax, located after the bidirectional RNN, transforms temporal features into a probability distribution. Its main functions are: completing trend category classification (e.g., rising / falling / stable); and providing confidence expression: the probability distribution output by Softmax can serve as a quantitative indicator for predicting risk zones.
[0022] The data processed by the bidirectional RNN and Softmax originates from the temporal feature sequences output by the front-end temporal attention module and the two-dimensional convolutional feature extractor, which already includes the results of abrupt change point identification. Therefore, it can be reused in the auxiliary path for key change moments. The auxiliary output complements the main output and mainly includes: trend category probability distribution (rising / falling / stable and their probability values); nutritional status classification results (as a segmented supplement to nutritional scores, such as normal / mild deficiency / severe deficiency); and risk confidence information (calculated from the difference in Softmax probability distributions and used for risk band construction).
[0023] By designing a bidirectional RNN and Softmax, a logical mutual constraint relationship is formed between the main output and the auxiliary output: when there is a contradiction between the trend prediction and the nutrient score, the auxiliary output can trigger a verification to ensure the reliability and consistency of the final fertilization recommendation.
[0024] S03. Multi-temporal image sequences are transmitted to the deep recognition model. A one-dimensional temporal convolutional layer identifies spectral abrupt change points in the spectral temporal data of the multi-temporal image sequences. The identified spectral abrupt change points serve as the guiding terms of the temporal attention module, thereby giving the model sensitivity to changes in physiological state.
[0025] S04. The multi-output task module has multiple parallel task decoding headers, which are used to receive data from the backbone feature extraction module and realize the scoring of the current nutrient status, prediction of future trends, and suggestions for variable fertilization.
[0026] S05. Based on the uncertainty estimation mechanism, output the prediction confidence interval and band channel importance interpretation information.
[0027] S06. Feedback and Self-Learning Closed-Loop Optimization: A field memory vector is generated for each plot. This vector stores the plot's environmental, crop, and historical response characteristics. After harvest, the actual yield, NDVI, and fertilization execution records for each plot are collected to form feedback pairs. An adaptive loss reweighting mechanism is used to update the model weights, achieving local adaptive optimization across cycles and crops. This step evolves the model from "single-time intelligence" to "field memory-driven long-term intelligence," possessing the potential for federated learning-style evolution.
[0028] In this embodiment, step S01 periodically acquires multi-band image sequences (including core bands such as red, green, red edge, and near-infrared) of specific leaf positions of crops, and simultaneously records the acquisition time, growth period, weather conditions (temperature, humidity, and irradiance) and soil information (moisture content and basic nutrients) corresponding to each image frame. All information is processed by tensor quantization to form a unified input, constituting time-series spectral-environment dual-modal sequence data. The time-series spectral-environment dual-modal sequence data at multiple times form a multi-temporal image sequence, which serves as the input to the deep recognition model.
[0029] To enhance the system's responsiveness to sudden nutritional changes, this invention introduces a one-dimensional derivative abrupt change point extraction algorithm into the image time series to calibrate spectral abrupt change points (such as red-edge reflectance jumps and red light slope inflection points). These points serve as guiding terms for the model's attention mechanism, thereby endowing the model with structural sensitivity to changes in physiological state. The spectral abrupt change point calibration method is as follows: Let the spectral time series data sequence be , The spectral time series data represents time t, where T is the total number of spectral time series data points, typically representing 4–10 reproductive stages (e.g., V4 / V6 / V8 / ejaculation stage / filling stage, etc.). The spectral time series data sequence is normalized, and the first derivative sequence of the spectral time series data sequence is calculated. The first-order derivative sequence is smoothed using a moving average kernel for noise reduction, with a window length of K=2 or 3. Then, abrupt change point detection is performed based on the first-order derivative sequence. This detection includes amplitude abrupt change detection and direction abrupt change detection. The amplitude abrupt change detection is determined by judging inequalities. Whether it is valid, among which The standard deviation of the first derivative sequence. The threshold is the amplitude multiple. If it holds, an amplitude abrupt change is considered to exist; if it does not hold, an amplitude abrupt change is considered not to exist. The direction abrupt change is determined by a judgment inequality. If the condition is met, a directional abrupt change is considered to exist; otherwise, no directional abrupt change is considered to exist. If an amplitude abrupt change or both amplitude and direction abrupt changes occur at a certain moment, that moment is marked as a spectral abrupt change point, and a mask vector is output. ,if This indicates that a drastic change occurs in the spectrum at time t, and time t is the spectral abrupt change point. This indicates that the point is relatively stable, and time t is not a point of spectral abrupt change.
[0030] In this embodiment, the one-dimensional derivative mutation point extraction algorithm is lightweight, has low computational complexity, is suitable for edge deployment, is tolerant of noisy data, and can set multiple threshold levels; it is highly interpretable and easy to form a map; it has the ability to provide early warning of sudden nutrient excess or deficiency.
[0031] To endow the model with structural sensitivity to sudden changes in crop nutrient status, this embodiment proposes using the mutation point mask vector as a guide term for the attention mechanism. This is achieved by: 1) assigning a weight-enhancing bias to the location of the mutation point during attention weight calculation; and 2) incorporating a mutation-guided offset into the location embedding encoding, thereby adjusting the model's temporal perception path. This guidance mechanism enables the model to perceive and respond to spectral mutation points such as sudden increases in red-edge reflectance and abrupt changes in red light absorption during training and inference, thus detecting abnormal fluctuations in physiological states earlier and improving the model's robustness and interpretability.
[0032] Specifically, the process by which spectral mutation points, serving as guiding terms for the attention mechanism of deep recognition models, endow the models with sensitivity to changes in physiological states is as follows: Obtain the binary mask vector ,Will The attention mechanism of embedded deep recognition models has two embedding methods: 1. Attention weight recalibration, using the binary mask vector Convert to a weight correction vector and recalculate the attention score vectors for all time steps of the temporal attention module. Then The normalized input is then fed into the softmax layer as the attention distribution; where This represents the original attention score vector at all times of the temporal attention module. For the recalculated attention scoring vector, This is a mutation enhancement factor, with a value between 0.5 and 2.0. This method structurally enhances the attention score at mutation points, naturally making the model pay more attention to the moment of change.
[0033] II. Position biasing mechanism, which adjusts the binary mask vector A mutation guidance vector is generated after a linear mapping layer or an embedding layer. , will mutation guide vector The updated position is obtained by weighted fusion with the original temporal position embedding of the deep recognition model. The updated position is then embedded into the encoding layer of the deep recognition model. The weighted fusion formula is as follows: Where P is the original temporal position embedding of the deep recognition model. This indicates the updated position embedding. This is to guide the bias factor. This approach is equivalent to changing the model's location encoding of time series, thereby affecting the contextual modeling method. It causes the model to begin to favor abrupt change time points in its structural encoding, affecting not only the score but also the structural changes in the computational path.
[0034] In summary, the model's sensitivity to changes in physiological state stems from three aspects: 1. Attention weight shift, which makes the model pay more attention to regions of dramatic spectral changes and detect nutritional change trends earlier; 2. Representation path adjustment, where the encoder generates stronger gradients for mutation points, which is beneficial for learning locally sensitive features; 3. More focused backpropagation of training loss, making the model's weights for mutation points more stable during training and improving prediction robustness.
[0035] In this embodiment, the multi-output task module has 5 parallel task decoding headers, which are used to receive data from the backbone feature extraction module and output 5 output tasks with mutual constraint logic. The 5 output tasks and mutual constraint logic are shown in the table below: As shown in the table above, the mutual constraint logic among the current nutrient status score, future trend prediction, variable fertilization recommendations, band channel importance explanation information, and prediction confidence interval is as follows: the current nutrient status score is a prerequisite for variable fertilization recommendations; the future trend prediction is automatically validated when it contradicts the current nutrient status score; the variable fertilization recommendations depend on the current nutrient status score being <0.7 and the future trend prediction being downward; the band channel importance explanation information is used to provide interpretability to users; and the prediction confidence interval is linked with the variable fertilization recommendations to display the risk zone.
[0036] The risk zone refers to the confidence interval or decision boundary sensitivity range constructed around the model output (such as nutrient score, recommended dosage). It is used to show users the credibility of the current output value, the decision tolerance boundary, and whether the recommendation has robustness. For example, if a deep recognition model outputs a current nutrient status score of 0.62, a confidence interval of [0.54, 0.70], a trend prediction of decline (85%), a recommended topdressing dosage of 6.0 kg / mu, and a risk zone interval of ±1.5 kg / mu, the results can be interpreted as follows: the confidence interval indicates that the model score may fluctuate between 0.54 and 0.70; the risk zone interval of ±1.5 kg / mu indicates that the recommended dosage has a stability range of approximately 75%; if the user implements a dosage between [4.5, 7.5] kg / mu, the effect risk is controllable; if it exceeds this interval, the model will prompt "high decision uncertainty, review recommended".
[0037] In this embodiment, the consistency of the mutual constraint logic is ensured by using the edge weight matrix of the graph structure and the mutual constraint loss function during training. The implementation process is as follows: Construct a graph structure between multiple output tasks , where the set of nodes This represents 5 output tasks, and the edge set E represents the logical dependencies between the output tasks. Each edge... Corresponding to one edge weight , border rights To represent the consistency constraint strength between the two output tasks, a 5x5 sparse graph structure is constructed, and edge weights are set. The trainable parameter matrix can be a fixed value (such as 1 or 0.8) or dynamically learned during the training phase.
[0038] The mutual constraint loss function is: , in Represents the total loss function. to This represents the loss formula for the first to nth output tasks, where n=5. These represent the outputs of the i-th and j-th tasks to input x, respectively. Represents the distance metric function. This is the mutual constraint strength adjustment coefficient (e.g., 0.1~0.5). For border rights.
[0039] This embodiment uses a mutual constraint loss function to train the deep recognition model. If the nutritional status score output by the deep recognition model is 0.88, but the trend prediction is downward, the inconsistency will be penalized by the loss function. At the same time, it encourages the suggested dosage and score to maintain numerical logical consistency. During the training process, a set of "low inconsistency / high consistency" output combinations is gradually converged, enhancing the structural integrity of the model. In this embodiment, the uncertainty estimation mechanism has two implementation methods. One is the MC Dropout mechanism, which keeps Dropout active during the inference phase of the deep recognition model, allowing the deep recognition model to output uncertainly. Furthermore, it calculates the mean and standard deviation of multiple results to construct a confidence interval, and the predicted score falls within this interval. Inside, among which To output the average value multiple times, To output the standard deviation, One is to represent the confidence coefficient; the other is to use a Bayesian neural network or deep ensemble to construct multiple weights to initialize different models, and to take the statistical distribution of the output of each model. The output interval reflects the degree of uncertainty and consistency between the models.
[0040] In this embodiment, the nutrient score, trend prediction result, and confidence interval output from step S04 are jointly input into a fertilization rule engine based on an uncertainty estimation mechanism. The fertilization rule engine outputs variable fertilization suggestions (e.g., applying 8 kg / mu of ammonium bicarbonate within 3 days), uncertainty intervals (e.g., [0.62, 0.75]), and band interpretation diagrams (e.g., red-edge channel weight reaches 44%). This allows the results to have structured characteristics, enabling them to be directly accessed by farmer apps, agricultural service platforms, or variable control devices.
[0041] This invention involves selecting multiple treatment groups in a maize experimental field at the Chinese Academy of Agricultural Sciences and collecting images at different stages of the growth period. The STCA-Net model is used as input for image sequences and weather / soil parameters to generate nutrient scores and recommendations. Variable topdressing recommendations are manually implemented. After harvest, the control yield and spectral response are compared with the original predicted values to identify errors, which are then used as feedback for model iteration. The model generates "high confidence" recommendations for blocks where yield is increased by 10–12% and fertilizer application is reduced by approximately 9% (simulated prediction data).
[0042] The method described in this embodiment is applicable to the nutritional management of field crops (such as corn, rice, rapeseed, etc.) at different growth stages and has broad application potential.
[0043] The deep learning model can be applied to nutrient management at different growth stages of field crops (such as corn, rice, and rapeseed), demonstrating broad application potential. The time-series spectral acquisition equipment is commercially available and suitable for various crops; it has completed small-sample training and structural validation in experimental fields, and is capable of short- to medium-term deployment; it also features on-demand tailoring capabilities, making it suitable for edge computing or cloud deployment environments.
[0044] Example 2 This embodiment discloses a crop fertilizer efficiency regulation device 300 based on time-series spectroscopy, including a processor 304 and a memory 301. Optionally, the device may further include a communication interface 302 and a bus 303. The processor 304, communication interface 302, and memory 301 can communicate with each other via the bus 303. The communication interface 302 can be used for information transmission. The processor 304 can call logical instructions in the memory 301 to execute the crop fertilizer efficiency regulation method based on time-series spectroscopy described in the above embodiment.
[0045] Furthermore, the logic instructions in the aforementioned memory 301 can be implemented as software functional units and, when sold or used as independent products, can be stored in a computer-readable storage medium.
[0046] The memory 301, as a computer-readable storage medium, can be used to store software programs and computer-executable programs, such as the program instructions / modules corresponding to the methods in the embodiments of this disclosure. The processor 304 executes functional applications and data processing by running the program instructions / modules stored in the memory 301, thereby realizing the crop fertilizer efficiency regulation method based on time-series spectrum in the above embodiments.
[0047] The memory 301 may include a program storage area and a data storage area. The program storage area may store the operating system and applications required for at least one function; the data storage area may store data created based on the use of the terminal device. Furthermore, the memory 301 may include high-speed random access memory and may also include non-volatile memory.
[0048] Example 3 This disclosure provides a computer-readable storage medium storing computer-executable instructions configured to execute the above-described crop fertilizer efficiency regulation method based on time-series spectroscopy.
[0049] The aforementioned computer-readable storage medium may be a transient computer-readable storage medium or a non-transitory computer-readable storage medium.
[0050] The technical solutions of this disclosure can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes one or more instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the method described in this disclosure. The aforementioned storage medium can be a non-transitory storage medium, including: a USB flash drive, a portable hard drive, a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk, and other media capable of storing program code; it can also be a transient storage medium.
[0051] The foregoing description and accompanying drawings fully illustrate embodiments of this disclosure to enable those skilled in the art to practice them. Other embodiments may include structural, logical, electrical, procedural, and other changes. The embodiments represent only possible variations. Individual components and functions are optional unless explicitly required, and the order of operation may vary. Parts and features of some embodiments may be included in or replace parts and features of other embodiments. Moreover, the terminology used in this application is for descriptive purposes only and is not intended to limit the scope of protection. As used in the description herein, the singular forms “a,” “an,” and “the” are intended to equally include the plural forms unless the context clearly indicates otherwise. Similarly, the term “and / or” as used herein means including one or more of the associated listed items and all possible combinations thereof. Additionally, when used in this application, the term "comprise" and its variations "comprises" and / or "comprising" refer to the presence of stated features, integrals, steps, operations, elements, and / or components, but do not exclude the presence or addition of one or more other features, integrals, steps, operations, elements, components, and / or groups thereof. Without further limitations, an element defined by the phrase "comprises a..." does not exclude the presence of other identical elements in the process, method, or apparatus that includes said element. In this document, each embodiment may focus on the differences from other embodiments, and similar or identical parts between embodiments can be referred to mutually. For methods, products, etc., disclosed in the embodiments, if they correspond to the method section disclosed in the embodiments, the relevant parts can be referred to the description of the method section.
[0052] Those skilled in the art will recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of the embodiments of this disclosure. Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the specific working processes of the systems, devices, and units described above can be referred to the corresponding processes in the foregoing method embodiments, and will not be repeated here.
[0053] The methods and products (including but not limited to devices and equipment) disclosed in the embodiments herein can be implemented in other ways. For example, the device embodiments described above are merely illustrative. For instance, the division of units may be merely a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. In addition, the coupling or direct coupling or communication connection shown or discussed between each other may be through some interfaces, and the indirect coupling or communication connection between devices or units may be electrical, mechanical, or other forms. The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units, that is, they may be located in one place or distributed across multiple network units. Some or all of the units may be selected to implement this embodiment according to actual needs. In addition, the functional units in the embodiments of this disclosure may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.
Claims
1. A method for regulating crop fertilizer efficiency based on time-series spectroscopy, characterized in that: Includes the following steps: S01. Construct a multi-temporal image sequence that integrates spectral changes and environmental information; S02. Construct a deep recognition model with temporal convolution and attention fusion mechanisms. The deep recognition model includes a one-dimensional temporal convolutional layer, a backbone feature extraction module, and a multi-output task module connected in sequence. The backbone feature extraction module is composed of multiple temporal convolutional layers and a temporal attention module stacked together. The temporal convolutional layer models the trend evolution of spectral reflectance at different time points and is used to extract spectral temporal features. The temporal attention module realizes dynamic weighting of key bands. S03. Multi-temporal image sequences are transmitted to the deep recognition model. A one-dimensional temporal convolutional layer identifies spectral abrupt change points in the spectral temporal data of the multi-temporal image sequences. The identified spectral abrupt change points serve as the guiding terms of the temporal attention module, thereby giving the model sensitivity to changes in physiological state. S04. The multi-output task module is equipped with multiple parallel task decoding headers, which are used to receive data from the backbone feature extraction module and realize the current nutrient status scoring, future trend prediction, and variable fertilization suggestions. S05. Based on the uncertainty estimation mechanism, output the prediction confidence interval and band channel importance interpretation information.
2. The crop fertilizer efficiency regulation method based on time-series spectroscopy according to claim 1, characterized in that: Step S01 specifically involves periodically acquiring multi-band image sequences of specific leaf positions of crops, while simultaneously recording the acquisition time, growth period, weather conditions, and soil information corresponding to each image frame. All information is processed by tensor quantization to form a unified input, constituting time-series spectral-environment dual-modal sequence data. The time-series spectral-environment dual-modal sequence data from multiple moments form a multi-temporal image sequence.
3. The crop fertilizer efficiency regulation method based on time-series spectroscopy according to claim 1, characterized in that: The method for calibrating spectral abrupt change points is as follows: Let the spectral time series data sequence be , Let represent the spectral time series data at time t, where T is the total number of spectral time series data. The spectral time series data sequence is normalized, and the first derivative sequence of the spectral time series data sequence is calculated. The method for identifying abrupt changes is based on a sequence of first-order derivatives. This identification includes both magnitude and direction abrupt changes. The magnitude abrupt change determination is performed using the relevant inequality. Whether it is valid, among which The standard deviation of the first derivative sequence. The threshold is the amplitude multiple. If it holds, an amplitude abrupt change is considered to exist; if it does not hold, an amplitude abrupt change is considered not to exist. The direction abrupt change is determined by a judgment inequality. If the condition is met, a directional abrupt change is considered to exist; otherwise, no directional abrupt change is considered to exist. If an amplitude abrupt change or both amplitude and direction abrupt changes occur at a certain moment, that moment is marked as a spectral abrupt change point, and a mask vector is output. , This indicates that time t is the spectral abrupt change point. This indicates that time t is not a spectral abrupt change point.
4. The crop fertilizer efficiency regulation method based on time-series spectroscopy according to claim 3, characterized in that: Spectral mutation points, serving as guiding terms for the attention mechanism of deep recognition models, endow the models with sensitivity to changes in physiological states as follows: Get the mask vector ,Will The attention mechanism of embedded deep recognition models has two embedding methods:
1. Attention weight recalibration, adjusting the mask vector Convert to a weight correction vector and recalculate the attention score vectors for all time steps of the temporal attention module. Then The normalized input is then fed into the softmax layer as the attention distribution; where This represents the original attention score vector at all times of the temporal attention module. For the recalculated attention scoring vector, It is a mutation enhancer; II. Position biasing mechanism, which adjusts the mask vector A mutation guidance vector is generated after a linear mapping layer or an embedding layer. , will mutation guide vector The updated position is obtained by weighted fusion with the original temporal position embedding of the deep recognition model. The updated position is then embedded into the encoding layer of the deep recognition model. The weighted fusion formula is as follows: Where P is the original temporal position embedding of the deep recognition model. This indicates the updated position embedding. This is a guide bias factor.
5. The crop fertilizer efficiency regulation method based on time-series spectroscopy according to claim 1, characterized in that: The current nutrient status score, future trend prediction, variable fertilization recommendations, band channel importance explanation information, and prediction confidence interval are mutually constrained. The mutual constraint logic is as follows: the current nutrient status score is a prerequisite for variable fertilization recommendations; the future trend prediction will automatically verify when it contradicts the current nutrient status score; the variable fertilization recommendations depend on the current nutrient status score being <0.7 and the future trend prediction being downward; the band channel importance explanation information is used to provide interpretability to users; and the prediction confidence interval and variable fertilization recommendations are linked to display risk zones.
6. The crop fertilizer efficiency regulation method based on time-series spectroscopy according to claim 5, characterized in that: The consistency of the mutual constraint logic is ensured by using the edge weight matrix of the graph structure and the mutual constraint loss function during training. The implementation process is as follows: Construct a graph structure between multiple output tasks , where the set of nodes Let there be n output tasks, and let the set of edges E represent the logical dependencies between the output tasks. Each edge... Corresponding to one edge weight , border rights To represent the consistency constraint strength between two output tasks, construct an n*n sparse graph structure and set edge weights. A trainable parameter matrix that can be either fixed or dynamically learned during the training phase; The mutual constraint loss function is: , in Represents the total loss function. to This represents the loss formula corresponding to the first to nth output tasks. These represent the outputs of the i-th and j-th tasks to input x, respectively. Represents the distance metric function. This is the mutual constraint strength adjustment coefficient. For border rights.
7. The crop fertilizer efficiency regulation method based on time-series spectroscopy according to claim 1, characterized in that: There are two ways to implement uncertainty estimation mechanisms. One is the MC Dropout mechanism, which keeps Dropout active during the inference phase of the deep recognition model, allowing the deep recognition model to output uncertainly. It then calculates the mean and standard deviation of multiple results to construct a confidence interval, with the predicted score falling within this interval. Inside, among which To output the average value multiple times, To output the standard deviation, One is to represent the confidence coefficient; the other is to use a Bayesian neural network or deep ensemble to construct multiple weights to initialize different models, and to take the statistical distribution of the output of each model. The output interval reflects the degree of uncertainty and consistency between the models.
8. The crop fertilizer efficiency regulation method based on time-series spectroscopy according to claim 1, characterized in that: It also includes step S06, feedback and self-learning closed-loop optimization, generating a field memory vector for each plot, which stores the environmental, crop and historical response features of the plot. After harvest, the actual yield, NDVI and fertilization execution records of the plot are collected to form feedback pairs. An adaptive loss reweighting mechanism is used to update the model weights to achieve local adaptive optimization across cycles and crops.
9. A crop fertilizer efficiency regulation device based on time-series spectroscopy, comprising a processor and a memory storing program instructions, characterized in that: The processor is configured to execute, when running the program instructions, the crop fertilizer efficiency regulation method based on time-series spectrum as described in any one of claims 1 to 8.
10. A storage medium storing program instructions, characterized in that, When the program instructions are executed, they perform the crop fertilizer efficiency regulation method based on time-series spectrum as described in any one of claims 1 to 8.
Citation Information
Cited By
Method and system for detecting release effect of sustained-release drug based on AI
CN121768697A
