1 Introduction

Sorghum halepense (L.) Pers. (johnsongrass) (Fig. 1a) is one of the most competitive weeds in maize (Zea mays L.) crops worldwide, and it reduces yields up to 100 % (Vasilakoglou et al. 2005). As S. halepense is a perennial weed with a vegetative reproductive system, several studies using on-ground data from detailed surveys and proximal sensing showed that this weed is spatially distributed in compact patches (Andújar et al. 2011; Guerrero et al. 2013). Maize is a summer crop that requires irrigation at least once per week under our Mediterranean conditions which increases the persistent risk of johnsongrass in the earlier phases of the crop and the competition. This johnsongrass infestation requires two or three expensive and selective herbicide treatments that usually are broadcast applied by the farmers (Andújar et al. 2013). Therefore, there is a need for more diligent and efficient optimization of herbicide management practises which is consistent with the sustainable weed control practises regulated by the European and the Spanish legislation.

Fig. 1
figure 1

a Johnsongrass (Sorghum halepense) patches in the Espabera maize field. The early detection of johnsongrass in maize crops represents a major challenge and serious complexity because both species are in the Poaceae family and show analogous spectral patterns, an extraordinarily similar appearance and a parallel phenological evolution. b Spectral index values (ExG and NDVI for RGB and TTC sensors, respectively) for each class (weed, crop and bare soil)

Remote sensing using imagery from a satellite or a piloted airborne vehicle has been previously considered an effective technique to detect the weed patches in a late phenological stage of the crop (e.g. flowering). The images were used to design site-specific weed patch control at the field or broader scales against other worldwide problematic weeds such as wild oat and cruciferous (Castillejo-González et al. 2014; de Castro et al. 2012, 2013). Nevertheless, the imagery from these platforms lacked sufficient temporal and spatial resolution to detect weeds at the early phenological stage, because the suitable image resolution on the ground, i.e. pixel size or the ground sample distance (GSD) to achieve this objective must be 5 cm or less (Peña et al. 2015). Therefore, three of the most important variables to consider in the use of remote imagery for early weed mapping are the image spatial and spectral resolutions and the phenological stage of the crop and weeds.

With higher spatial and temporal resolutions, the finer details can be discriminated in the images. Currently, the remote platforms that generate this high spatial resolution imagery are the unmanned aerial vehicles (UAVs, or drones or UASs, unmanned aerial systems) (Lopez-Granados 2011; Pajares 2015), which can embed sensors with different spectral ranges. As a result of flights conducted at low altitudes (<120 m above ground level according to Spanish Regulations for UAVs <25 kg), the UAV images cannot cover the entire study plot, requiring a sequence of overlapped (side-lap and forward-lap) images. These multiple overlapped images must be stitched together and orthorectified with an aerial-triangulation procedure to create an accurately georeferenced orthomosaicked image of the entire plot. The procedure to obtain a precise orthomosaick for the UAV imagery using the RGB and the multispectral sensors was previously developed by our research group, with more details provided in the literature (Gómez-Candón et al. 2014). Therefore, any classification algorithm to detect and map weeds using UAV imagery must accurately work with the orthomosaicked image generated from the entire field. This provides robustness to the classification and mapping methodology because the inherent high variability present when working with the entire fields is not covered when single UAV image (not orthomosaicked) is used.

Although the UAV imagery has showed the ability for an early detection of broadleaved weeds in sunflower crops (Torres-Sánchez et al. 2013; López-Granados et al. 2016), the early detection of johnsongrass in maize crops presents serious complexity because both species are in the Poaceae family and show analogous spectral patterns, an extraordinarily similar appearance and a parallel phenological evolution (Fig. 1a), which are factors that present a major challenge for their detection in actual maize field scenarios. These difficulties in the discrimination of other grass weed species, such as Avena sterilis L. (wild oat) and Lolium rigidum L. (ryegrass) in a grass crop such as wheat were previously reported with the use of on-ground multispectral data (Gómez-Casero et al. 2010; López-Granados et al. 2008). Furthermore, the separation of weed from crop becomes more complicated when very high spatial resolution UAV imagery (usually <5 cm) must be processed. This is because the individual small pixels do not capture the distinctiveness of so similar weed and crop plants, which increases the intra-class spectral variability. An additional problem in the detection of johnsongrass is the morphology of the leaves which are linear and thin, whereas the broadleaved weeds have a more compact shape and the pixels that cover them have lower spectral mixing. One of the typical methods to solve this problem is the segmentation of the imagery, which is a process that groups adjacent pixels into spectrally and spatially homogeneous objects that contain more information than the individual pixels, leading to a more significant and correct interpretation of the imagery. In our case and to discriminate johnsongrass patches in maize crops using the UAV imagery, the segmentation consisted of multipixel regions defined by maize rows, weed patches and bare soil.

Blaschke (2010) provided an overview of the development of object-based-image-analysis (OBIA) methods and suggested that the pixel paradigm was beginning to show cracks. The OBIA represents a significant new trend in remote sensing for many monitoring programs. This procedure has been previously used in the detection of vegetation and weeds in sunflower and wheat crops using UAV (López-Granados et al. 2016; Peña et al. 2015; Torres-Sánchez et al. 2013; Torres-Sánchez et al. 2014; Torres-Sánchez et al. 2015) or satellite imagery (Castillejo-González et al. 2014; de Castro et al. 2013). As an element of an overall research program to investigate the prospects and limitations of UAV imagery in the accurate mapping of a set of problematic and perennial weeds in early season crops, our objective was to determine the potential to create johnsongrass maps from multiple UAV overlapped frames that were mosaicked as a first step in a further classification with an OBIA procedure at the field-scale. The accurate discrimination of the johnsongrass patches that grew between the maize crop rows at the same early phenological stage could lead to the design of a field program for the site-specific herbicide applications in the entire field.

2 Materials and methods

2.1 Study site

The study was performed in two maize fields on flat ground (average slope <1 %) at the farms of Ribera and Espabera that were located in Córdoba (southern Spain). The maize crops were sown on April 14 and 15, 2014 at 6 kg ha−1 in rows that were spaced 0.70 m apart. The emergence of the maize plants began 15 days after sowing. The area of the studied parcels was approximately 1 ha, and the parcels were naturally infested with johnsongrass patches (Fig. 1a). The weed and crop plants were at the stage of 4–6 leaves unfolded, from the BBCH extended scale (code 14) (Meier 2001). This phenological stage of weed and crop was selected because the time-window to control this weed is very narrow and beyond 4–6 leaves unfolded, an efficient weed control is more difficult to achieve.

2.2 UAV campaign: cameras and altitudes

The UAV flights were carried out on May 6, 2014. To prepare the flight route, the coordinates of the corners of the experimental maize fields were determined with a Trimble Geo-XH Differential GPS (DGPS). Then, each flight route was programmed into the UAV software for each planned altitude and required degree of image overlapping. The imagery was collected with two different cameras that were mounted separately on a quadrocopter UAV model md4-1000 (microdrones; GmbH, Siegen, Germany). The flight routes for each camera were programmed and automated, and the pilot performed manually only the take-off and the landing. One of the cameras was a low-cost, digital, still, visible spectrum camera, model Olympus PEN E-PM1 (Olympus Corporation, Tokyo, Japan), which acquired 12-megapixel images in true red-green-blue (RGB) colour with 8-bit radiometric resolution. The other sensor was a multispectral, rolling shutter camera, model Tetracam mini-MCA-6 (TTC, Tetracam Inc., Chatsworth, CA, USA), which acquired 1.3-megapixel images composed of six individual digital channels arranged in a 2 × 3 array that acquired images with either an 8-bit or a 10-bit radiometric resolution. This camera had user-configurable band pass filters (Andover Corporation, Salem, NH, USA) of 10-nm full-width at half maximum and centre wavelengths at B (450 nm), G (530 nm), R (670 and 700 nm), R-edge (740 nm) and near infrared (NIR, 780 nm). Detailed information about specifications of UAV flights, vehicle and cameras can be found in Torres-Sánchez et al. (2013).

The UAV imagery was collected from three different altitudes: 30, 60 and 100 m. To ensure that the images were effectively orthorectified and mosaicked, a sequence of 30 % side-lap and 60 % forward-lap imagery for each of the flight mission cameras at the different altitudes was collected. These overlaps were programmed according to our previous experience for mosaicking UAV imagery acquired on other cereal crops (Gómez-Candón et al. 2014; Torres-Sánchez et al. 2014). The images that were collected with the visible camera were used directly after downloading to the computer, whereas those collected with the multispectral camera required preprocessing. The multispectral sensor collected the images of each channel in raw format and stored separately on six individual CF cards embedded in the camera. Therefore, an alignment process was used to group into a single file the six images taken from each waypoint using Tetracam PixelWrench 2 software (Tetracam Inc., Chatsworth, CA, USA).

For the calibration of the spectral data, a 1 × 1 m barium sulphate standard spectralon® panel (Labsphere Inc., North Sutton, NH, USA) was placed in the middle of the fields. Spectral corrections were performed using an image spectralon® panel by averaging the image digital values for each band from this panel and comparing them to those ground-truth digital values for the panel. A correct calibration factor based on this empirical relationship was then computed per each band. These factors were then applied to each band of the image in order to obtain corrected digital values for each image pixel (Rey-Caramés et al. 2015).

2.3 Image preprocessing: mosaicking

A total of 36, 15 and 5, and 98, 32 and 21 images were acquired at 30, 60 and 100 m altitudes for the visible and multispectral cameras at Ribera and Espabera maize fields, respectively and were used to create each orthomosaicked image. The software used to stitch the images together was Agisoft Photoscan Professional Edition (Agsoft LLC, St. Petersburg, Russia). On the day of the UAV flights, an on-ground sampling procedure was conducted that consisted of placing 50 1 × 1 m sampling areas, or squared frames (made by lacquered aluminium), regularly distributed in a 7 × 7 m grid throughout the two experimental plots. All the frames included johnsongrass-free and infested areas and were georeferenced using a Trimble Geo-XH Differential GPS (DGPS). The frames were used later in the validation of the OBIA procedure for the discrimination of weeds, as explained in the section on the evaluation of the performance of the OBIA algorithm.

To generate the georeferenced, orthomosaicked images, six squared frames were used as artificial terrestrial targets (ground control points, GCPs) to assign geographical coordinates to the images. Then, the software automatically performed the orthorectification and mosaicking of the imagery set into a single image of each entire maize field.

2.4 Johnsongrass detection and mapping: spectral discrimination and OBIA algorithm

Due to our preliminary pixel-based analyses on the orthomosaicked imagery did not supply any satisfactory results (data not shown), we developed the following procedure. To generate weed mapping from UAV imagery, two phases are required (Lopez-Granados 2011): (i) bare soil and vegetation discrimination and (ii) crop and weed discrimination. The first phase produces an image with two classes: bare soil and vegetation (crop and weeds together). The second phase masks crop and weeds. To determine the potentiality of each sensor with regard to both steps, spectral values of maize, johnsongrass and bare soil were extracted. These spectral values were collected in 20 random samples for each soil use, sensor and location from the orthomosaicked images at 30 m altitude. Then, two indices were derived from these spectral values: the Excess Green (ExG, Eq. 1) (Woebbecke et al. 1995) for the RGB camera and the NDVI (Eq. 2) (Rouse et al. 1973) for the multispectral TTC camera. Both indices were selected because they enhanced the spectral differences of the vegetation pixels against the non-vegetation ones in the UAV images, as was previously reported by Wan et al. (2014).

$$ ExG=2g-r-b;\kern0.5em \mathrm{being}\;r=\frac{R}{R+G+B}\kern0.24em g=\frac{G}{R+G+B}\;b=\frac{B}{R+G+B} $$
(1)
$$ \mathrm{NDVI}=\frac{NIR-R}{NIR+R} $$
(2)

Figure 1b displays the box and whiskers plots for each soil use and both spectral indices (corresponding to the RGB and multispectral sensors) and locations. The boxes show a robust separation between vegetation (weed and crop) and bare soil. By contrast, a deficient spectral separability between weed and crop was obtained since corresponding boxes are quite similar and the range of whiskers of weed and crop causes an overlapping and an evident risk of misclassification. So that, the successful discrimination of weeds could not rely on a strategy of only size or spectral differentiation based on spectral indices and pixels, but rather on the relative position of each plant with reference to the maize-row structure. The accurate crop-row classification as a first step for a further mapping of weeds growing between these crop rows was previously considered in the literature for proximal and remote sensing (Montalvo et al. 2012; Torres-Sánchez et al. 2014), and this would be also particularly applicable in this study. Those spectral limitations were solved by implementing the following OBIA algorithm. To summarize, each orthomosaicked imagery obtained for each maize field was segmented with OBIA methodology to partition the images into homogeneous multipixel objects that covered crop rows, weed patches and bare soil using a bottom-up region-merging process, the multiresolution algorithm. The imagery was subdivided based on several parameters (i.e. band weights, scale, colour, shape, smoothness and compactness) that were defined by the user (TRIMBLE 2013). Finally, the OBIA methodology classified each image by combining the spectral, contextual and morphological information, among other features, of the objects that were created.

The OBIA procedure that was developed for the johnsongrass mapping task was designed using the commercial software eCognition Developer 8.9 (Trimble GeoSpatial, Munich, Germany). The procedure was based on the weed mapping algorithm that was fully described in our previous work conducted in a maize field using non-mosaicked imagery (Peña et al. 2013). However, the procedure presented in this study was original and included some improvements and variations that were related to the use of two sensors, three flight altitudes and orthomosaicked images. Thus, the combination of use of a visible camera (low-cost sensor), higher flight altitudes (at higher altitude flights, a larger surface area was flown over) and an entire image of each plot (superior field variability is inherently considered in the performance of the algorithm) was specifically addressed in this paper. These inclusions introduced an important novelty; when the algorithm accurately worked under these conditions and detected and mapped johnsongrass at the field-scale, the primary contribution was that a complex objective and a relevant increase in the management efficiency of this problematic weed was achieved.

The detailed analysis of the images is described in the following steps:

  • Field segmentation into sub-parcels: The orthomosaicked images collected with each camera for each flight altitude were segmented into small parcels by applying the quadtree-based segmentation process. The size of these sub-parcels is user-configurable and in our case, was 5 × 5 m. Each individual sub-parcel was automatically and sequentially analysed to address the spatial and spectral variability of the crop (Fig. 2a, b).

  • Sub-parcel segmentation into objects: The orthoimages were segmented using a multiresolution algorithm to create an object-based framework of homogeneous multipixel objects that corresponded to two classes: vegetation (crop and weeds) and non-vegetation (bare soil) objects (Fig. 2c). The segmentation setting was 1, 10, 0.6, 0.4, 0.5 and 0.5 for band weights, scale, colour, shape, smoothness and compactness, respectively. Because these objects were produced from merging of spectrally and spatially homogeneous pixels, the objects contained new information such as orientation, position, size and shape, among others, which was used in the subsequent phases of the OBIA procedure. For each object that was created, the strategy was to create a set of spectral, textural, morphological and contextual attributes for use in the image analysis procedure in such way that the basic information unit for the image classification was based on objects and not on pixels.

  • Discrimination of vegetation objects: Following the segmentation of the sub-parcels, the vegetation (crop and weeds) objects were discriminated from the bare soil ones. The two spectral indices described before were used for the classification as follows: the ExG (Eq. 1) for the RGB camera and the NDVI (Eq. 2) for the multispectral camera. The determination of the optimal ExG and NDVI values for the vegetation discrimination was conducted by using the automatic thresholding algorithm described in Torres-Sánchez et al. (2015). In this paper, the algorithm was successfully applied in UAV imagery for the vegetation detection in three herbaceous crops, including maize. This algorithm adapts the Otsu’s method (Otsu 1979) to the object-based framework using the eCognition programming language, implementing an iterative process until finding the optimal discrimination value. In this process, the algorithm tests all the possible thresholding values and finally selects the one that maximizes the between-class variance of the image. In order to deal with the spatial and spectral variability observed in the UAV images, an optimal thresholding value was separately computed for each one of the 5 × 5 m sub-parcels described in the first step. This automation has the advantages of being easy to compute, stable, not dependent on other a priori information and also improves the transferability of the OBIA rule set to other images.

  • Maize crop-row detection: Following the classification of the vegetation and the bare soil objects, those objects that corresponded to vegetation were merged to determine the crop-row structure (Fig. 2d). Previously, the orientation of the crop row was determined with an iterative process in which the image was sequentially segmented into stripes with several combinations of different angles (from 0 to 180°, with 1° of increasing ratio), creating temporal stripe-based segmentations. Finally, the crop-row orientation was selected according to the stripes that showed a higher percentage of the area with vegetation objects. At this point, a new segmentation level, named up-level, was created above the original multiresolution one, named low-level, in which the image was segmented to create a mesh of stripes with the same direction as the selected crop-row orientation angle. This process resulted to a hierarchical segmentation framework between the up- (stripe-based segmentation) and the low-levels (multi-resolution segmentation). Next, the stripes in the up-level with high percentage of vegetation objects in the low-level were classified as crop rows, following a criteria of maximizing the vegetation coverage. After a stripe was classified as a maize crop-line, the separation distance between rows (0.7 m) was used to mask the adjacent stripes within this distance to avoid the classification of areas with potential high weed infestation as crop rows (Fig. 2e).

  • Johnsongrass patches and weed-free maps: Following the classification of the crop rows, the remaining stripes were classified as crop-row buffers (strings in contact with the crop rows) and non-crop areas in the up-level. This classification was one of the advantages of segmentation because the multiscale image object hierarchy allowed that each segmentation output contained a different semantic level that represented the information in the image data at the different resolutions simultaneously (Blaschke 2010). Each object knows its context and its neighbourhood, and the variables were calculated as information that belonged to an object, a sub-object or a super-object. In this study, the hierarchical relationship between the up- and the low- segmentation levels was used to discriminate between the crop and the johnsongrass. The vegetation sub-objects (in the low-level) that were located either in the crop row or in the non-crop super-objects (in the up-level) were classified either as maize or as weeds, respectively. The remaining vegetation sub-objects located in the buffer super-objects were classified following a criterion of minimum spectral distance, i.e. an unclassified vegetation sub-object was assigned to the maize or the johnsongrass class depending on a higher degree of spectral similarity to the ExG and the NDVI values of the surrounding maize or the weed sub-objects for the visible and the multispectral images, respectively (Figs. 2f, g).

  • Site-specific treatment maps: Following the mapping of weed-patches and weed-free areas, the algorithm built a grid-based framework at an upper level and applied a chessboard segmentation process to generate the grids of user-configurable size. For example, in this investigation and according to particularities of the maize crop and the weed control machinery, the grid size was 0.5 × 0.5 m. Therefore, a new hierarchical structure was generated between the grid super-objects at the upper level and the sub-objects classified as maize, johnsongrass or bare soil at the lower level. Next, the site-specific treatment maps were created according to the johnsongrass coverage maps that were previously delineated.

Fig. 2
figure 2

Partial views of the outputs from the OBIA algorithm at each step. a A section of the orthomosaicked multispectral (RGB+NIR) image, in magenta one of the 5 × 5 m in which the OBIA algorithm is displayed. b Zoom of the 5 × 5 m portion. c Segmentation to calculate row orientation. d Lines showing crop-row orientation. e Crop-row classification (blue) and adjacent stripes (yellow). f Classification of objects of crop rows (in green), johnsongrass (red) and bare soil (in grey). g Johnsongrass infestation map (blue marine indicates maize rows; green indicates johnsongrass patches; blue indicates bare soil)

2.5 OBIA algorithm evaluation

To evaluate the performance of the OBIA algorithm for each case study (each field, camera and flight altitude), the classification results obtained for the maize-row discrimination and the johnsongrass patch identification were compared with the ground data observed in the 50 ground-truth 1 × 1 m square sampling frames that were located in each field. Each frame was georeferenced with a DGPS and was photographed to compare the on-ground weed infestation (observed weed density) with the outputs from image classification (estimated weed density). With a comparison of the observed data and the classification outputs for each maize field, the OBIA algorithm was evaluated by quantifying the number of correct frames, i.e. those sampling frames in which all the johnsongrass plants were correctly attributed to weed objects. Alternatively, incorrect frames (e.g. crop plants classified as weed objects or weed plants classified as bare soil objects) were also classified into three different types: (i) underestimated, i.e. johnsongrass-infested frames in which some weed plants were detected but some other weed plants remained undetected by the OBIA algorithm; (ii) false negative, johnsongrass-infested frames in which no weeds were detected and (iii) false positive, i.e. frames in which weeds were overestimated (e.g. crop plants or bare soil elements were classified as weed objects).

3 Results and discussion

As explained before, the aim of this study was to evaluate the prospects and limitations of UAV orthoimagery in the accurate mapping of early johnsongrass at maize fields using an OBIA procedure in order to design of a site-specific herbicide program in the entire fields.

3.1 Orthomosaicked imagery

Figure 3a, 3b presents the visible and multispectral orthomosaicked images from the Ribera maize field. The orthoimages obtained for Espabera location were not shown to minimize the number of figures. All the orthomosaicked images showed an accurate crop-row matching between consecutive overlapped images, which guaranteed the good performance in the subsequent classification of the image. Other authors used orthomosaicked imagery taken from maize fields with the objective of determining the effect of the topography on the rate of cross-pollination (Haarbrink and Eisenbeiss 2008). Even taking into account that they did not need to map the crop rows, they found that an accurate orthoimage was a difficult task because of the highly repetitive arrangement of any herbaceous crop and the problems in locating local invariant features or GCPs to perform the aerotriangulations. According to our results, continuity in the maize crop-lines occurred, which were accurately matched in the contiguous overlapped imagery during the mosaicking process for both sensors. Therefore, one of the critical results presented in this study was the strength of the mosaicking method that was used. If the orthoimagery obtained for each maize field was not sufficiently accurate, the crop rows would be incorrectly georeferenced and appear broken or even moved. This robustness has strong implications and is relevant for the accurate segmentation of vegetation objects (crop and weeds) and the further discrimination of the crop-row objects and those referred to weeds placed in the inter-row areas.

Fig. 3
figure 3

a Portion of the orthomosaicked image of the Ribera maize field generated at 30 m flight altitude using the visible-RGB camera. b Portion of the orthomosaicked image of the Ribera maize field generated at 30 m flight altitude using the RGB + near infrared multispectral camera. c and d Details of the weed seedling map considering high and low weed infestation at 30 m flight altitude using RGB camera and OBIA algorithm at Espabera field: blue marine indicates maize rows; green indicates johnsongrass patches; blue indicates bare soil. e Example of disagreements in the classification of frame no. 45 at Espabera field: on-ground image of squared frame no. 45. f Misclassification: underestimation of johnsongrass (green). g Correct detection of johnsongrass (green). h Example of disagreements in the classification of frame no. 18 at Espabera field: on-ground image of squared frame no. 18. i Misclassification: false positive of johnsongrass (green). j Correct detection of johnsongrass (green)

3.2 Johnsongrass detection and mapping as affected by spatial and spectral resolutions and flight altitudes

As expected, the spatial resolution and the length of flights were affected by sensors and flight altitudes. The pixel resolutions or GSD of the visible and the multispectral cameras ranged from 1.14 to 3.8 cm and from 1.62 and 5.51 cm for the 30 and 100 m flight altitudes, respectively. The values represented 1.3 (i.e. 1.14 cm by 1.14 cm) and 2.62 cm2, and 14.44 and 30.3 cm2 of actual ground area, respectively in the corresponding images. Considering that the smaller GSD had the higher spatial resolutions, any of these spatial resolutions were noticeably higher than those obtained by Armstrong et al. (2007), who used multispectral images from a piloted aircraft flying at a 300 m altitude in maize fields for weed detection in the early season.

The images captured by Armstrong et al. (2007) from that altitude resulted in pixel resolutions that ranged from 12.1 (146.41 cm2 of ground area) to 16.7 cm (278.9 cm2 of ground area), depending on slight variances in the altitude of the aircraft. With those GSD, the reliable early weed patch detection was not achieved, and they concluded that refinements in the sensor spatial and spectral resolutions were necessary to increase the ability to successfully detect early season weed infestations; a specific suggestion was that enhancement could be provided with ground-based systems. However, the spatial resolution imagery generated by the UAV, cameras and flight altitudes tested in our study improved 10.5-fold compared with the resolutions provided by those authors. Thus, our results showed that one of the crucial features for johnsongrass mapping was the kind of remotely sensed data acquired rather than to have to use ground-based systems when the crop and weeds were at the very early phenological stages.

As a rule of thumb, at least four pixels are required to detect the smallest objects within an image (Hengl 2006). According to this rule, if we consider that the minimum patch size of johnsongrass was approximately 25 cm2 of ground area (i.e. 5 cm × 5 cm), the discrimination of a patch that size would occur at a flight altitude of 100 m or lower and with the use of both cameras. By contrast, if the detection of individual johnsongrass plants is the objective, the pixel size will range from 1 to 4 cm, which corresponded to flight altitudes from 30 to 100 m in the case of the visible-RGB camera and from 30 to 60 m altitudes in the case of the multispectral camera. Therefore, the spatial resolution supplied by the UAV, the sensors and the altitudes tested in this study were highly improved compared with the other studies and should be considered an accurate first step to increase the reported results by Armstrong et al. (2007) based on other remotely sensed data.

A decrease in the flying altitude increased the number of images per hectare, consequently reducing the area covered by each single image. Thus, the decrease in the flying altitude resulted in an increase in both the flight length (11 min 20 s, and 26 min 14 s) and the sequence of images (36 and 98 images ha−1) for the RGB and the multispectral cameras at a 30 m altitude, respectively. By contrast, 4 min 5 s, and 9 min 20 s and 5 and 21 images ha−1 for the RGB and the multispectral cameras at a 100 m altitude were recorded. That higher number of overlapped images at a lower flight altitude and using the multispectral sensor affected the complexity of the image mosaicking procedure to obtain an orthoimage that covered the entire study area. Considering these interactions between flight altitudes and camera types, one of the initial decisions when the user programs the flight mission is to determine the combination of altitude and kind of camera that is appropriate to maintain a steady quality of the spatial and spectral resolution of images. This is fundamental to optimize the weed detection given the potential UAV battery limitations.

3.3 Detection and mapping of maize rows and johnsongrass patches as affected by sensor and flight altitude

The maize crop rows were discriminated and mapped with 100 % accuracy using the OBIA procedure for all the flight altitudes and with both camera types. The detection of crop rows was successful, even with a high or low johnsongrass presence, as shown in Fig. 3c, d. Thus, although the row distribution of the maize plants could have lost the correct orientation with respect to the actual central row axis, the OBIA algorithm successfully identified the maize lines following the correct crop rows, even with sowing failures and johnsongrass patches within and between the rows. These satisfactory results were also the first consequence of a correct orthomosaicking procedure that created an image of the entire maize field, which indicated that (i) the geometric distortion caused by low flight altitudes was eliminated and (ii) the aerotriangulation and the percentage of end-lap and side-lap image overlapping were correct. This outcome was crucial when a maize crop (or any herbaceous crop) was in the early stages in a repetitive design and severe difficulties were present in finding local invariant features to perform the aerotriangulation. Therefore, the resultant orthomosaicked images showed a high-quality landscape metric and an accurate matching of crop rows for consecutive overlapped images to ensure the proper functioning for the subsequent classification analyses.

Table 1 shows the percentage of correct and incorrect classifications of the johnsongrass patches and the type of misclassification recorded in the erroneous detections for the Ribera and Espabera maize fields, flight altitudes and sensors. The discrimination of the johnsongrass patches at the lowest altitude (30 m) was obtained with 92 and 86 % classification accuracy with the multispectral camera in the Ribera and Espabera fields, respectively. These accuracy values were consistent with those of Thomlinson et al. (1999) who standardized the overall accuracy at 85 % for minimum established values. Other authors (Wan et al. 2014) mapped Spartina alterniflora (an invasive herb species in mangroves) using UAV imagery and OBIA reaching a 94 and 87 % of accuracy of the classification performance, respectively. They suggested that their methodology was potentially applicable to other similar areas and/or other invasive species.

Table 1 Accuracy evaluation of weed maps according to observed johnsongrass inside the sampling squared frames and classified weed coverage from OBIA algorithms affected by camera (visible ExG; and multispectral NDVI) and flight altitudes for Ribera and Espabera maize fields

Regarding the incorrectly classified frames at the 30 m altitude, the majority of errors were attributed to false positives (8 %) at Ribera and underestimated (9 %) (Fig. 3e–f) to false positives (5 %) at Espabera (Fig. 3h–j). No frame was classified as false negative, i.e. weed objects were not classified as maize or soil objects. From the total errors committed, the false positives (weeds were overestimated or the crop plants or bare soil elements were classified as weed objects) and the underestimations (johnsongrass-infested frames in which not all the emerged weed plants were detected with the OBIA algorithm) could be more acceptable to the farmers than the false negative errors (johnsongrass-infested frames in which no weeds were detected). This is due to the farmers who usually prefer a conservative option rather to avoid leaving any weed patches untreated. At the higher flight altitudes, the multispectral camera accuracy was lower (accuracy ranged from 67 to 41 %), and the errors were caused by false positives (e.g. 11 and 31 % at Ribera for the 60 and 100-m flight altitudes, respectively) but also by underestimations (28 and 36 % at Espabera for the 60 and 100 m altitudes, respectively) and by false negatives (ranging from 8 to 18 % in both locations for the 60 and 100 m altitudes, respectively). All these errors indicated that a number of the johnsongrass patches would be only partially detected (the weed was not detected in totality) or even completely undetected, and therefore, the weed coverage map would not display the entire current weed infestation.

From the RGB camera results for accuracy, the values did not exceed 67 % in any scenario considered, and similar to the results from the multispectral camera, the classification accuracy decreased in all the images with an increase in flight altitude. The site-specific herbicide maps for the Ribera and Espabera fields based on the weed coverage obtained at a 30 m altitude using the RGB and multispectral cameras are shown in Fig. 4. This figure presents the identical surface of the corresponding fields to easily compare the percentage of surface that would need herbicide treatment. According to these figures, 2 and 4 % of the Ribera field surface required johnsongrass control based on the RGB or the multispectral camera images, respectively. For the Espabera field, 7 and 15 % of the field surface required johnsongrass site-specific control. Because the multispectral camera provided improvements of 25 and 20 % at the 30 m altitude compared with the RGB camera images, the most accurate site-specific herbicide maps were those that indicated that 4 and 15 % of the field surface required herbicide control for the Ribera and Espabera fields, respectively. Thus, 96 and 85 % of the Ribera and Espabera maize fields did not require herbicide treatment providing a relevant saving on the use of expensive herbicides, and in addition to the economic benefit, with subsequent agronomic and environmental repercussions as well.

Fig. 4
figure 4

a Site-specific herbicide maps at Ribera and b Espabera maize fields using RGB camera and flying at 30 m altitude. Green indicates field surface requiring weed control. c Site-specific herbicide maps at Ribera and d Espabera maize fields using the multispectral (RGB+NIR) camera and 30 m altitude. Green indicates field surface requiring johnsongrass control

For the detection of johnsongrass-free zones (no-weed columns in Table 1), the multispectral camera detected 100 % of the zones in the Ribera and Espabera fields from an altitude of 30 m. The combination of the full detection of the maize rows and the successful discrimination of weed-free areas has relevance to the decision-making of the farmer. For example, a farmer could choose not to use the site-specific machinery in the johnsongrass-free zones with 100 % assurance. Consequently, the optimization of the field operation included not only a reduction and an objective rationalization in the application of herbicides but also a savings in time and costs (e.g. human resources for driving the field equipment and the use of fuel).

The more accurate results obtained with the multispectral camera have important implications because the visible camera was a low-weight and a low-cost sensor, whereas the weight of the multispectral camera was approximately double and the price was 40-fold higher than that of the RGB sensor (currently). Moreover, the RGB camera generated higher spatial resolution imagery, and at the same altitude, the number of images ha−1 to acquire was lower and covered a larger area of study in each overlapped image in comparison with the multispectral camera. This difference has consequences related to the UAV energy limitations (a larger area covered per flight would lower the battery requirements). Joining all these relationships among flight altitudes and camera types, the farmer or the user of the UAV technology must decide on the correct combination of flight altitude and camera according to their objectives, which must ensure the detection of the weeds and the minimisation the herbicide use, with consideration also to the potential UAV battery limitations.

Therefore, it is important to determine the balance among sensor performance and improvements in accuracy, particularly because an objective of this research was to optimize the control operations. The farmers and agronomic consultants must evaluate all these factors. A priority for site-specific weed control research (even at the detriment of increased costs) is to obtain the highest accuracy. However, with the extrapolation of our results to a practical point of view, the decrease in accuracy with the RGB camera might not be significant for some farmers or consultants. For example, despite the lower results for accuracy with the RGB camera, the sum of correct and false positive frames detected at Ribera and the correct and underestimated frames at Espabera were 89 and 90 %, respectively (Table 1). As previously stated, the false positive error was the most acceptable of the misclassifications for the farmer, which was followed by underestimation. Considering a balance of these factors, the farmers and other users could decide to compromise on the accuracy of the final site-specific treatment maps to optimize costs not only on herbicide use but also on the UAV technology (e.g. sensors and number of batteries) to keep a more equilibrated balance.

4 Conclusions

Johnsongrass is a very competitive weed of maize crops in many agricultural areas worldwide. To promote proper and efficient johnsongrass control according to current European regulations (as also suggested by other environmentally concerned authorities, farmers, herbicide distributers and consultants worldwide), the development of accurate tools to detect and map johnsongrass patches and to delineate the surface area requiring site-specific herbicide treatment based on the weed coverage is crucial. This study evaluated the performance of an OBIA algorithm on the imagery acquired with a UAV that was equipped with separate visible spectrum (RGB spectral range) and multispectral cameras (RGB+NIR spectral range) and that was programmed for three flight altitudes (30, 60 and 100 m) at Ribera and Espabera maize fields to classify and map patches of johnsongrass. Then, as the most critical tool for the streamlining of herbicide application, a site-specific treatment map based on the most accurate weed coverage map was delineated for each location. For the overall accuracy of classification, the optimum results were found for the multispectral camera from a 30 m flight altitude, with slight differences between locations. The corresponding johnsongrass coverage map was used for generating the site-specific herbicide treatment maps that provided potential 96 and 85 % savings in herbicide use for the Ribera and Espabera maize fields. The identification of the areas that would not require treatment was certainly a relevant savings of very expensive herbicides, which could have further economic, agronomic and environmental repercussions. Although the accuracies for detecting johnsongrass using the RGB camera at the same flight altitude were lower in both locations, we suggest that the farmer or the user of the UAV technology must decide which combination of flight altitude and camera will most address their objectives to ensure the detection of weeds and to minimize the herbicide use and to also consider the potential UAV battery limitations. Thus, the balance between sensor performance and improvements in accuracy must be weighed. In conclusion, with the use of UAV imagery and an automatic OBIA algorithm, satisfactory results were obtained for the accurate identification of johnsongrass patches and in the savings on herbicide use for controlling johnsongrass, one the most harmful and competitive weeds in maize. The results have strong implications because of the emphasis on opportunities to extrapolate these results to other areas worldwide, e.g. the Mediterranean basin, Argentina-Brazil and the corn-belt in the USA, among others.