Content uploaded by Giorgio Morales
Author content
All content in this area was uploaded by Giorgio Morales on Jul 11, 2022
Content may be subject to copyright.
The authors are solely responsible for the content of this paper, which is not a refereed publication. The citation of this work should
state that it is from the Proceedings of the 15th International Conference on Precision Agriculture. EXAMPLE: Last Name, A. B. &
Coauthor, C. D. (2018). Title of paper. In Proceedings of the 15th International Conference on Precision Agriculture (unpaginated,
online). Monticello, IL: International Society of Precision Agriculture.
Generation of Site-specific Nitrogen Response
Curves for Winter Wheat using Deep Learning
Giorgio Morales1, John Sheppard1, Amy Peerlinck1, Paul Hegedus2, Bruce
Maxwell2
1Gianforte School of Computing, Montana State University, Bozeman, MT.
2Land Resources & Environmental Science, Montana State University, Bozeman, MT.
A paper from the Proceedings of the
15th International Conference on Precision Agriculture
June 26-29, 2022
Minneapolis, Minnesota, United States
Abstract.
Nitrogen fertilizer response (N-response) curves are tools used to support farm management
decisions. The conventional approach to model an N-response curve is to fit crop yield in
response to a range of N fertilizer rates as a quadratic or exponential function. The purpose of
the model is to identify the profit maximizing N rate given the costs of nitrogen and the price
paid for the crop yield. We show that N-response curves are not only field-specific but also site-
specific and, as such, economic optimal (profit maximizing) rates should be calculated for each
field each year prompting the use of on-field precision experiments (OFPE) utilizing precision
agriculture technologies. We propose a methodology that allows deriving N-response curves
automatically instead of using parametric curve fitting approaches. Thus, we obtain a specific
non-parametric N-response curve for each 10 m x 10 m cell of a grid virtually draped on the
field. First, we train a convolutional neural network called Hyper3DNetReg using remote sensed
data collected during the early stage of the winter wheat growing season (March) to predict crop
harvest yield values . The neural network models the behavior of the field under different
environmental and terrain conditions. Then, we use the trained prediction model to obtain an N-
response curve per cell by simulating what would be the yield response given a range of
nitrogen rate values between 0 and 150 pounds per acre (lbs/ac). Results show that the shape
of the N-response curve depends on the region of the field from which it was calculated. Related
work will address the problem of generating prescription maps that merge the site-specific
economic optimal rates calculated from our N-response curves while also minimizing the overall
fertilizer applied and the number of jumps between consecutive cells’ nitrogen rates.
Keywords.
Nitrogen response curves, Site-specific, Deep learning.
Proceedings of the 15th International Conference on Precision Agriculture
June 26-29, 2022, Minneapolis, Minnesota, United States
2
Introduction
The economic optimal nitrogen rate (EONR) is defined as the nitrogen rate beyond which there
is no actual profit for the farmers. Estimation of the EONR is usually obtained after fitting pre-
selected, parametric yield response functions to crop yield data. Some traditional approaches
assume plateau-type, quadratic, and exponential functions (Bullock & Bullock, 1994; Watkins, et
al., 2010; Kablan, et al., 2017). Other approaches are based on basic agronomic principles, as is
the case of the Liebig response functions (Ackello-Ogutu, Paris, & Williams, 1985). It is worth
mentioning that different crop yield data models can produce different EONR estimations
(Meisinger, Schepers, & Raun, 2008).
Previous works have documented that the EONR is highly dependent on the type of crop, soil,
environmental conditions, and other factors (Nyiraneza, et al., 2010; Tremblay, et al., 2012).
Some work has tried to account for the field and year variability by introducing stochasticity on
crop yield models that used conventional functional forms, obtaining better results than their
deterministic counterparts (Tembo, et al., 2008; Tumusiime, et al., 2011; Boyer, et al., 2013).
However, the variability of the nitrogen response (N-response) functional form across the fields
has not been widely addressed by previous work (Anselin, Bongiovanni, & Lowenberg-DeBoer,
2004; Maxwell, et al., 2018).
We argue that trying to fit a single N-response curve for an entire field implies the strong
assumption that the field is homogeneous and behaves similarly everywhere. However, it is
reasonable to consider that this assumption does not always hold when there exists variability in
the terrain of the field (e.g., terrain slope and soil composition). Thus, in this work, we consider
that N-response curves are not only field-specific and year-specific but also site-specific.
In particular, we propose to use a convolutional neural network (CNN) called Hyper3DNetReg
(Morales & Sheppard, 2021) that maps the spatial features into predicted yield values. The CNN
acts as a complex crop yield data model whose implicit functional form is non-parametric and is
learned from the data. We use an early-yield prediction dataset and show how different N-
response curves can be generated for different regions of a field using the learned yield prediction
model. In addition, we explain that having site-specific N-response curves allows for site-specific
N recommendations.
Proposed Methodology
Datasets
In previous work, we presented a curated early-yield prediction dataset of winter wheat (Morales
& Sheppard, 2021; Hegedus, 2022). In this case, the early-yield prediction of winter wheat can be
viewed as a regression problem where its explanatory variables are determined by the set of
features collected during the growing season (March). Below, we report the list of features that
were used:
• Nitrogen rate applied.
• Terrain slope.
• Terrain elevation.
• Terrain aspect.
• Topographic position index (TPI).
• Sentinel-1 Vertical Transmit-Vertical Receive Polarization (VV) backscatter coefficients.
• Sentinel-1 Vertical Transmit-Horizontal Receive Polarization (VH) backscatter
coefficients.
The yield value in bushels per acre (bu/ac) is considered the response variable of the regression
problem. The yield is measured during the harvest season (August) using a combine harvester
equipped with a yield monitor that collects georeferenced values from the field. Hence, the data
acquired from the winter wheat fields in March is used to predict crop yield values in August of
Proceedings of the 15th International Conference on Precision Agriculture
June 26-29, 2022, Minneapolis, Minnesota, United States
3
the same year.
Fig 1. Image rasters corresponding to the G1 field. (a) Yield raster. (b) Automatic extraction of
𝟓 × 𝟓
m pixel patches.
Each field was divided into a grid where each cell represents a region of
10 ×10
m. By doing this,
all the data was aggregated on a scale of 10 m. Fig 1a shows a yield raster for one of the fields
of our dataset from 2018 where each pixel represents an area of 10 m x 10 m.
We chose Hyper3DNetReg as the yield prediction model due to its ability to exploit spatial
information from its two-dimensional (2-D) input patches by using 2-D and 3-D convolutional
filters. Thus, the collected data rasters need to be pre-processed to create the training datasets
used to fit the Hyper3DNetReg models. Specifically, we automatically extract square patches
using a
5 × 5
pixel window allowing a maximum overlap of 0.75, as shown in Fig 1b. This
approach differs from traditional methods that rely on models trained on 1-D features regardless
of the spatial distribution (Gonzalez-Sanchez, Frausto-Solis, & Ojeda-Bustamante, 2014; Kim &
Lee, 2016; Wei, et al., 2020). Table 1 shows the total number of extracted samples and the years
of observation for each field used in our experiments. Here, F1 and G1 are two fields of winter
wheat from two different farms in Montana.
Table 1. Number of samples and years of observation for each field
Field
# Samples 1st
Year
# Samples 2nd
Year
# Samples 3rd
Year
Observed Years
F1
408
316
317
2016, 2018, 2020
G1
484
497
614
2016, 2018, 2020
Yield Prediction
In this section, we use the collected datasets to train and test the Hyper3DNetReg models. These
models are field-specific; that is, they are trained on data of a given field from previous years
(2016 and 2018 in this case) and used to predict yield maps using data from the last observed
year (2020 in this case) of the same field.
In our previous work (Morales & Sheppard, 2021), we showed that 2-D deep regression models
yielded better results than regression models that use a single output. Therefore, in this work, we
only use Hyper3DNetReg models with output windows of
5 × 5
pixels (i.e., the input window size
matches the output window size), as shown in Fig 2.
After training the Hyper3DNetReg models using data from 2016 and 2018, they are tested on
Proceedings of the 15th International Conference on Precision Agriculture
June 26-29, 2022, Minneapolis, Minnesota, United States
4
data from 2020. Here, the predicted yield maps are obtained after averaging the resulting
overlapping output patches. We refer the reader to our previous work (Morales & Sheppard, 2021)
for further details on how the predicted yield maps are generated. Table 2 shows the metrics
obtained after comparing the generated predicted maps and their corresponding ground truth.
The metrics that are used for comparison are root mean square error (
𝑅𝑀𝑆𝐸
), root median square
error (
𝑅𝑀𝑒𝑑𝑆𝐸
), and average structural similarity using a windows size of 3 (
𝑆𝑆𝐼𝑀3
) and 11
(
𝑆𝑆𝐼𝑀11
). Fig 3 illustrates the comparison between the ground-truth maps and the predicted yield
maps that results from applying our Hyper3DNetReg network. The performance values shown in
Table 2 are slightly better than those shown in the original paper due to more careful
hyperparameter tuning.
Fig 2. Hyper3DNetReg yield prediction model using an
𝟓 × 𝟓
– pixel output window.
Table 2. Yield prediction results
Field
𝑅𝑀𝑆𝐸
𝑅𝑀𝑒𝑑𝑆𝐸
𝑆𝑆𝐼𝑀3
𝑆𝑆𝐼𝑀11
F1
10.74
6.93
41.63
61.71
G1
14.88
8.94
20.51
42.27
Fig 3. Yield prediction, square error map, and structural similarity map of the (a) F1 field and (b) G1 field.
Proceedings of the 15th International Conference on Precision Agriculture
June 26-29, 2022, Minneapolis, Minnesota, United States
5
N-response Curves
A site-specific Hyper3DNetReg model is a mapping from the feature space to the yield value
space. In our previous work, we demonstrated that the Hyper3DNetReg models trained for
different fields performed better than other traditional and more recent machine learning methods
(e.g., linear regression, stacked autoencoders, and 3-D CNNs). This implies that our
Hyper3DNetReg network models the mapping from the feature space to the yield value space
better than other approaches. Therefore, here we propose a method to generate N-response
curves that are specific to each location of the field using Hyper3DNetReg models. To do so, we
apply the learned Hyper3DNetReg model at each location of the field with varying nitrogen rate
values between 0 and 150 pounds per acre (lbs/ac) with a step size of 3 lbs/ac.
For example, Fig 4a depicts the original nitrogen rate map applied on F1 in 2020 and the
corresponding yield prediction. In contrast, Fig 4b, Fig 4c, and Fig 4d show the results of applying
constant nitrogen rates of 50, 75, and 100 lbs/ac, respectively.
Fig 4. Yield prediction for the G1 field using different N rates. (a) N rate values applied on the field during the growing
season (March 2020). (b) Uniform N rate of 50 lbs/ac. (c) Uniform N rate of 75 lbs./ac. (d) Uniform N rate of 100 lbs./ac.
From the yield maps generated after simulating using a wide range of N rates for the entire field,
we obtain an N-response curve for each
10 ×10
m cell of the field. Fig 5 and Fig 6 show six
different N-response curves generated from the F1 and G1 fields, respectively. Note that, in both
cases, different regions of the field react differently to the nitrogen rate applied. Specifically, some
regions of the fields reach a plateau for high N rates while others experience a rapid decline.
Proceedings of the 15th International Conference on Precision Agriculture
June 26-29, 2022, Minneapolis, Minnesota, United States
6
Fig 5. N-response curves generated for different regions of the F1 field.
Fig 6. N-response curves generated for different regions of the G1 field.
Proceedings of the 15th International Conference on Precision Agriculture
June 26-29, 2022, Minneapolis, Minnesota, United States
7
From Fig 5 and Fig 6, it is observed that the slope and the position of the local maximum of the
generated N-response curves vary depending on the field location. This is important because
traditional methods suggest that the EONR point can be found as the N rate at which the first
derivative of the N-response curve – which depends directly on the slope – is equal to a common
yield-nitrogen price ratio (Bullock & Bullock, 1994). Thus, considering that the EONR point is
estimated from a single N-response curve and that we are obtaining different N-response curves
for different regions of the field, we would be able to find different EONR points for different regions
of the field
It is worth mentioning that traditionally the EONR calculation assumes concave functional forms
with a single local optimum (e.g., quadratic and exponential functions). On the other hand, the N-
response curves generated by our non-parametric approach may have more than one local
optimum. This can be seen in two of the N-response curves shown in Fig 5 that have at least two
local maxima. Therefore, the traditional EONR calculation is not sufficient for these cases.
Furthermore, we argue that uncertainty plays a crucial role in yield prediction and EONR
estimation. Uncertainty may arise due to representational bias, training data variance, and
parameter uncertainty (Pearce, Brintrup, Zaki, & Neely, 2018). It can be quantified using
prediction intervals (PIs) that consist of an estimate of the upper and the lower bounds within
which a prediction will fall with a certain probability. For future work, we will present an N-response
curve generation method coupled with non-parametric PIs generated by the modified
Hyper3DNetReg models automatically.
Finally, we should consider that the EONR values obtained from our site-specific N-response
curves may differ significantly between neighboring cells. We refer to this phenomenon as
“jumps.” Hence, jumps put a strain on the farmer’s equipment, so it becomes necessary to
minimize the jumps when determining the prescription maps (Peerlinck, Sheppard, Pastorino, &
Maxwell, 2019). Therefore, future work will focus on generating prescription maps that merge the
site-specific economic optimum points calculated from our N-response curves while also
minimizing the overall fertilizer applied and the number of jumps between consecutive cells’
nitrogen rates.
Conclusion
Traditionally, EONR estimation is carried out assuming parametric N-response curves for an
entire field. In this work, we have proposed that N-response curves should be site-specific, and
their functional form can be learned from data.
In our experiments, we have used the Hyper3DNetReg convolutional neural network, which is an
accurate yield prediction model that can be used to generate N-response curves. Thus, our initial
results using two different winter wheat fields showed that different regions of the field have
different responses to the N fertilizer. Moreover, the N-response curves generated by our method
may have more than a single local optimum. Therefore, conventional EONR calculation methods
cannot be applied directly.
Future work will address the need of incorporating uncertainty quantification into the N-response
curve generation by using automatically generated prediction intervals. Furthermore, these
curves will be used to generate fertilizer prescription maps based on multi-objective optimization
while considering other factors such as the minimization of jumps.
Acknowledgements
The authors thank the team members of the On-Field Precision Experiment (OFPE) project for
their comments throughout the development of this work. This research was supported by a
USDA-NIFA-AFRI Food Security Program Coordinated Agricultural Project, titled “Using
Precision Technology in On-farm Field Trials to Enable Data-Intensive Fertilizer Management,”
Proceedings of the 15th International Conference on Precision Agriculture
June 26-29, 2022, Minneapolis, Minnesota, United States
8
(Accession Number 2016-68004-24769), and also by the USDA-NRCS Conservation Innovation
Grant from the On-farm Trials Program, titled “Improving the Economic and Ecological
Sustainability of US Crop Production through On-Farm Precision Experimentation” (Award
Number NR213A7500013G021).
References
Ackello-Ogutu, C., Paris, Q., & Williams, W. A. (1985). Testing a von Liebig Crop Response Function against Polynomial
Specifications. American Journal of Agricultural Economics, 67(4), 873-880.
Anselin, L., Bongiovanni, R., & Lowenberg-DeBoer, J. (2004). A Spatial Econometric Approach to the Economics of Site-
Specific Nitrogen Management in Corn Production. merican Journal of Agricultural Economics, 86(3), 675-687.
Boyer, C. N., Larson, J. A., Roberts, R. K., McClure, A. T., Tyler, D. D., & Zhou, V. (2013). Stochastic Corn Yield
Response Functions to Nitrogen for Corn after Corn, Corn after Cotton, and Corn after Soybeans. Journal of
Agricultural and Applied Economics, 45(4), 669–681.
Bullock, D. G., & Bullock, D. S. (1994). Quadratic and Quadratic-Plus-Plateau Models for Predicting Optimal Nitrogen
Rate of Corn: A Comparison. Agronomy Journal, 86(1), 191-195.
Gonzalez-Sanchez, A., Frausto-Solis, J., & Ojeda-Bustamante, W. (2014). Predictive ability of machine learning methods
for massive crop yield prediction. Spanish Journal of Agricultural Research, 12(2), 313-328.
Hegedus, P. (2022). Optimizing Site-Specific Nitrogen Fertilizer Management Based on Maximized Profit and Minimized
Pollution. PhD Thesis, Montana State University, Department of Land Resources and Environmental Sciences,
Bozeman, Montana.
Kablan, L. A., Chabot, V., Mailloux, A., Bouchard, M.-È. a., & Bruulsema, T. (2017). Variability in Corn Yield Response to
Nitrogen Fertilizer in Eastern Canada. Agronomy Journal, 109(5), 2231-2242.
Kim, N., & Lee, Y. (2016). Machine Learning Approaches to Corn Yield Estimation Using Satellite Images and Climate
Data: A Case of Iowa State. Journal of the Korean Society of Surveying, Geodesy, Photogrammetry and
Cartography, 34(4), 383-390.
Maxwell, B., Hegedus, P., Davis, P., Bekkerman, A., Payn, R., Sheppard, J., . . . Izurieta, C. (2018). Can optimization
associated with on-farm experimentation using site-specific technologies improve producer management
decisions? Proceedings of the 14th International Conference on Precision Agriculture. Montreal, Quebec,
Canada.
Meisinger, J., Schepers, J., & Raun, W. (2008). Crop nitrogen requirement and fertilizeation. Nitrogen in agricultural
systems, 49, 563-612.
Morales, G., & Sheppard, J. W. (2021). Two-dimensional deep regression for early yield prediction of winter wheat. SPIE
Future Sensing Technologies, 11914, pp. 49-63.
Nyiraneza, J., N'Dayegamiye, A., Gasser, M. O., Giroux, M., Grenier, M., Landry, C., & Guertin, S. (2010). Soil and Crop
Parameters Related to Corn Nitrogen Response in Eastern Canada. Agronomy Journal, 102(5), 1478-1490.
Pearce, T., Brintrup, A., Zaki, M., & Neely, A. (2018). High-Quality Prediction Intervals for Deep Learning: A Distribution-
Free, Ensembled Approach. Proceedings of the 35th International Conference on Machine Learning, (pp.
4072-4081).
Peerlinck, A., Sheppard, J., Pastorino, J., & Maxwell, B. (2019). Optimal Design of Experiments for Precision Agriculture
Using a Genetic Algorithm. 2019 IEEE Congress on Evolutionary Computation (CEC), (pp. 1838-1845).
Wellington, New Zealand.
Te mb o , G . , B r o rs e n , B . W . , E p pl i n , F. M. , & To st ã o , E . ( 2 0 08 ) . Cr o p I n pu t Re s p on s e F u n ct i o ns w it h St o c ha s t ic P la t e au s .
American Journal of Agricultural Economics, 90(2), 424–434.
Tremblay, N., Bouroubi, Y. M., Bélec, C., Mullen, R. W., Kitchen, N. R., Thomason, W. E., . . . Ortiz-Monasterio, I. (2012).
Corn Response to Nitrogen is Influenced by Soil Texture and Weather. Agronomy Journal, 104(6), 1658-1671.
Tumusiime, E., Brorsen, B., Biermacher, J. T., Mosali, J., Johnson, J., & Locke, J. (2011). Determining Optimal Levels of
Nitrogen Fertilizer Using Random Parameter Models. Journal of Agricultural and Applied Economics, 43(4),
541-552.
Watkins, K. B., Hignight, J. A., Norman, R. J., Roberts, T. L., Slaton, N. A., Wilson, C. E., & Frizzell, D. L. (2010).
Comparison of Economic Optimum Nitrogen Rates for Rice in Arkansas. Agronomy Journal, 102(4), 1099-
110 8.
Wei, M., Maldaner, L., Ottoni, P., & Molin, J. (2020). Carrot Yield Mapping: A Precision Agriculture Approach Based on
Machine Learning. AI, 1(2), 229-241.