Detection of Plant Location Based on Spectral Analysis Using GIS, GPS and Remote Sensing

: In this study, plant position determination was made based on multispectral remote sensing for high-precision agricultural applications targeting the plant itself. In order to determine the plant location, silage corn was planted. Ground control points were fixed for geo-referencing purposes on the subjects determined for the purpose of taking images. Multispectral images were taken with a UAV and plants were detected by image processing after spectral analysis. The plant positions in the images were determined with GIS and the difference between the real plant positions measured with RTK-GPS was determined by calculating rmse values. 96% of the plants in all images taken could be identified. The average rmse value calculated using the coordinates of the plants detected in the images and the real plant coordinates determined by RTK-GPS was found to be 87.99 mm.


INTRODUCTION
Today, agriculture has gained benefits such as greater productivity and economic efficiency from constantly evolving technological innovations.This technological development mainly focuses on the intensive mechanization of field applications that provide higher work rates to the operator.The trend of increasing efficiency with larger and more powerful machines has reached a critical point due to the risks of damage to soil, high chemical and high fuel input.Large-scale machines also appear to have the drawback of not being able to provide the basic needs of precision agriculture (Griepentrog et al., 2005).
The growth trend of machine sizes and weights will in the future be replaced by knowledge-based technologies that enable reliable autonomous field applications (Griepentrog et al., 2005).Such technologies may pave the way for agricultural practices based on each plant (Blackmore and Griepentrog, 2002;Griepentrog et al., 2003) In classical and traditional agriculture, variables are generally handled at the field level and fixed doses are used in field applications.New crop management strategies offer the solution of dividing the land into smaller parcels where soil and plant properties are similar in order to apply input or application dose at a more variable level.In some studies, much higher spatial resolution was used and inputs or applications based on the plant itself were included instead of smaller parcels.These systems, which require high automation and intensive information, are systems that aim to determine the needs of each plant separately and the application and input rate according to the needs of each plant (Plant Scale Farming) (Griepentrog andBlackmore 2007, Tillett et al. 1998).
Remote sensing is defined as the science and art of obtaining information about objects through measurements made from any platform and distance to evaluate spatial and temporal changes without physical contact (Vatandaş et al., 2005, Curran, 1985, Kavak, 1998).
The principle of remote sensing is based on the use of the differences in reflecting or emitting electromagnetic radiation of different wavelengths of all objects or phenomena on the earth in the detection of these objects or phenomena.Therefore, each object or phenomenon on earth will react differently to different wavelengths of electromagnetic energy, resulting in a unique spectral signature (Çorumluoğlu et al., 2007(Çorumluoğlu et al., , Aggarwal, 2004 By taking advantage of these reactions of plants to sunlight of different wavelengths, various experimental vegetation indices have been developed in order to determine some features of the vegetation in the use of remote sensing technique in the field of agriculture (Hatfield et al., 2019) The most common vegetation index used until recently was the normalized vegetation index (NDVI), and this index was developed by taking advantage of the high reflectance of plants for the form of energy in the near infrared wavelength and the high absorption of the energy in the red wavelength in the visible region.(Myneni et al., 1995Huang et al. 2021).

NDVI =
NIR -VIS NIR + VIS (1) In this equation, NDVI: Normalized Difference Vegetation Index NIR: Percentage of near-infrared wavelength light reflected from the plant VIS: The visible wavelength ray surface reflected from the plant The aim of this study is to develop a more effective and low-cost method based on remote sensing, which has not been used before in the academic field, in mapping plants in order to provide navigation data for applications that require precision in the plant scale in agricultural production.

MATERIALS AND METHOD
This study was conducted at Sarıcalar Research and Application Farm, Faculty of Agriculture, Selçuk University, in Konya province.In order to identify plants in the study, approximately 5 decares of silage corn were planted on May 16, 2018.In the research, a four-row, vacuum-pneumatic precision planting machine, driven by the tail shaft, was used.The machine inter-row spacing is 70 cm and the intra-row spacing is set to 16 cm.Hoeing was done with a tiller machine and irrigation and fertilization was done with a drip irrigation system.
The first sprout emerged on May 28, 2018, and the emergence was completed on June 09, 2018.During the cultivation period, hoeing was done once and weed spraying was done once.The corn in the parcels reached harvest maturity on September 19, 2018.
ADC Lite multispectral sensor was used to obtain remote sensing data (Figure 1).This sensor has a 3.2 megapixel (2048 x 1536 pixels) CMOS sensor and is capable of recording green, red and near infrared bands, equivalent to the TM2, TM3 and TM4 bands of the Landsat satellite.The operating voltage of the sensor is 5-12 V, and a 2-cell lithium polymer battery was used while taking images in the field with the camera.Some features of the sensor are given in Table 1.The reason for using multispectral sensors, which are remote sensing tools, instead of visual sensors in image acquisition, is to increase sensitivity by measuring the wavelengths of different wavelengths coming from the sun that are absorbed and reflected by plants, and to eliminate the disadvantages caused by excess light, shadow and other plants.It is possible to make a sharper discrimination since plants respond more specifically to properties such as absorption and reflection of the radiation in the wavelengths measured by this sensor.
For the purpose of taking measurements in the field, 3 parcels with a size of 2.8x2 m were determined.Ground control points (GCPs) were created by screwing a 20 cm diameter Teflon plate onto a 1 m long steel profile nailed to the 4 corners of the parcels (Figure 2).

Figure 2. GCPs fixed to the measurement points in the parcels
In the study, DJI brand Inspire 1 V2 model rotary wing UAV was used as a remote sensing platform (Figure 3).Some technical specifications of the UAVs used are given in Table 2.In the study, SATLAB brand SL 500 model RTK-GPS, which works according to the CORS-RTK principle and can measure with centimeter precision, handheld terminal, topcon brand carbon fiber pole and standard tripod with scales were used to determine the actual coordinates of ground control points and plants (Figure 4-5).Satlab GNSS Office Software and Google Earth software were used to make appropriate transformations of the location data received via GPS.Visualization and processing of location data taken from plants and ground control points, and georeferencing of remote sensing images were done with the QGIS GIS program.A standard laptop computer from Asus with an Intel Core i5 2.4 GHz processor, 4 GB memory and 320 GB hard drive was used to run the programs used and other data analyses.
After sprout emergence, the coordinates of the plants in the determined plots were measured with the highly accurate CORS-RTK GPS device.The coordinates of the plants recorded in Rw5 format by the GPS device were first uploaded to Satlab GNSS Office Software and converted into raw KML format to be uploaded to Google Earth Pro program (Figure 6).

Figure 7. Making appropriate transformations by uploading plant coordinates to Google Earth Pro Software
The resulting KML files were uploaded to the QGIS GIS program and converted into an ESRI shapefile file with the save as option (Figure 8).

Figure 8. Converting plant coordinates to ESRI shapefile by uploading them to QGIS program
In the study, NDVI, which is very sensitive to green parts, was used to determine plant positions.Images of the plants were taken between 15 and 20 July, when the weather conditions were suitable for UAV flight, 1 hour before and after the sun was at its steepest, when the sky was clear.Images were taken from a height of approximately 25 m (Figure 9).

Figure 9. Raw multispectral images taken from the parcels
The captured images were uploaded to the PixelWrench2 program, and firstly, the raw images were color processed from the index tool menu and enriched with false colors (Figure 10).

Figure 10. Raw image uploaded to PixelWrench2 program (top) and enriched version of the image (bottom).
When NDVI analysis is performed with the program, each pixel in the images is colored from red to green according to the size of the NDVI value from the color palette shown in Figure 11.Pixels with the highest NDVI value, that is, where vegetation is dense, are green, while other pixels are colored from green to red.In order to facilitate plant detection, all color palettes except green were assigned white color as shown in Figure 12, and as a result of NDVI analysis, the areas with vegetation were green and the other parts were white.The resulting NDVI image was exported in tiff format, loaded into the Fiji image processing program, and median and maximum filters were applied to make the objects stand out so that the plants became clear, and the image was converted into a binary image (Figure 14).

Figure 14. Converting the image to binary
The erode command was applied to separate the plants from each other on the image and to delete small non-plant objects.Then, plants were detected as objects from the 3D Object Counter menu and images were obtained in the form of center points, surface map and object map as seen in Figure 15.

Figure 15. Determining plant locations with 3D Object Counter
The image with plant center points was exported as tiff from the Fiji program.Since the ground control points to be used in georeferencing the images were deleted from the images during spectral analysis and image processing, the images were uploaded to the GIMP program to mark the ground control points on the image.At the same time, the enhanced image with ground control www.ijlsar.orgAvaliable at: 9 8 | 4 486 P a g e points, which was not subjected to any processing, was also loaded into the program as a bottom layer.The image with the plant center points was made transparent, allowing the GCPs to be seen in the lower layer (Figure 16).

Figure 16. Loading images in layers to the GIMP program and making the upper layer transparent
Then, GPCs were marked with a pen and their numbers were written next to them (Figure 17).The edited image was then exported as tiff to be uploaded to the CBS program.

Figure 17. Marking GPCs and writing their numbers
The image was then loaded into the QGIS GIS software via the open raster menu on the georeferencing tool.By selecting the Add Point tab, ground control points were selected one by one, and the coordinates of the ground control points previously measured by GPS were entered in the window that opened, as seen in Figure 18.After all the coordinates were entered, the transformation settings were made and the image was georeferenced with the start georeferencing tab and added to the map canvas, and then the GPS-measured coordinates of the plants where the image was taken were loaded as a measurement layer (Figure 19).

Figure 19. Georeferenced plant location image and plant coordinates
A new vector layer called image has been added for the image in which plants are detected from the add layer menu.Using the advanced digitization toolbar, points were added to the places where the plants were (Figure 21).

Figure 21. Saving plant positions to vector file with advanced digitization toolbar
Then, the image and measurement layers were entered into the attribute table and the create new area button was selected.By selecting first $x and then %y from the geometry option in the area creation window, a column containing the x and y coordinates of the plants was added to the attribute table.
The measurement and image layers were saved in dbf format, which can be opened by the Excel program from the save as menu and the values in the attribute table can be seen.These files were opened in the Excel program and the mean square error (rmse) value, which expresses the deviation between the measurement and the plant coordinates on the picture, was calculated according to equation 2 (Patterson et al., 2010).

RESULTS AND DISCUSSION
As a result of plant detection using image processing, 1 of the 45 plants in the first image could not be detected, and the other 44 could be detected.In two non-plant coordinates, the weeds on the row were perceived as plants.As a result of the plant detection for the second image, 3 of the 40 plants could not be detected and the other 37 could be detected.As a result of the plant detection for the third image, 1 of the 43 plants could not be detected, and the other 42 could be detected.Of the 128 plants in total in the sections where all the pictures were taken, 123 were identified and 5 of them could not be identified.
The root mean square error (rmse) values calculated using the plant coordinates obtained from the pictures and the real plant coordinates measured with GPS are given in Table 3  When Table 3 is examined, it is seen that the mean square errors expressing the distances between real plants and plants detected from pictures vary between 81.86 and 93.55 and the average is 87.99 mm.
In general, when the data obtained from all images was examined, it was determined that 96% of the plants could be detected and the distance between the real plant and the detected plants was 87.99 mm.Weiss and Biber (2011) obtained an average position accuracy of 0.03 m under field conditions in a study they conducted on plant detection and positioning for agricultural robots with the most advanced imaging sensors using 3D LIDAR sensors and RTK-GPS.
If the factors that cause the difference value to be relatively high in this study are examined, they can be listed as errors due to GPS, measurement error of ground control points on the image, errors due to georeferencing and image resolution.Since no other study has been conducted on plant detection with a similar approach to date, this study can be considered promising depending on future developments in GPS and imaging technology.

CONCLUSIONS
In this study, in order to determine the location, the plants were imaged with a multispectral camera connected to the UAV and spectral analysis was performed on the images taken.The images of the plants whose locations were determined by image processing were georeferenced and uploaded to GIS.The deviation between the plant positions determined by GIS and the actual plant positions determined by GPS was determined by calculating the rmse value.
The average distance between the detected plants and real plants was determined as 87.99 mm.It has been observed that this deviation may be caused by factors such as GPS accuracy, georeferencing error, and image resolution.Although this value is found to be relatively high for some sensitive agricultural applications based on the plant itself, better results can be obtained in future studies by taking into account the factors that cause the error to be high.

Figure 4 .Figure 5 .
Figure 4. SL 500 GPS system used in the study

Figure 6 .
Figure 6.Making appropriate transformations by uploading plant coordinates to Satlab GNSS Office Software

Table 2 . Features of the UAVs used Rotary wing UAV features Weight
3060 g (including propellers and battery) .