March 2023 was a month that has marked a significant milestone for Swift Lab Limited, as we successfully used AI to map and analyze crop aerial data for one of Kenya’s largest avocado farms. The main objective was to obtain accurate crop health data using our in-house AI product called SwiftAI, which has been specifically designed to perform tasks such as crop counting, line segmentation, gap analysis, crop health monitoring, weed detection, and species detection.
As we set out to map and analyze data for one the farm, we were both excited and apprehensive. Excited because we were confident in SwiftAI, which had matured to analyze aerial crop data with accuracy and speed. Apprehensive because we were pioneering a technology that had never been done before in Africa, and we knew we had to deliver. Our experience is a testament to the potential of advanced technology in agriculture and the need for tech adoption in Kenya. This is our story.
Why AI was the Solution
In any large-scale agricultural operation, a variety of factors can affect crop health, including weather, terrain, and varying levels of pest and weed infestation. But you quickly realize that traditional means of data analysis can not be sufficient and are especially poor when it comes to changing variables season after season; For example:
- Weather patterns and changes throughout the day and season
- Sparseness or density of trees in different avocado plots
- Different species of trees at varying levels of maturity
- Presence or absence of weed and pest infestations
- Varying line and tree spacing
- Differences in pruning techniques and tree shapes
- Different stages of flowering in different plots
The list of uncontrollable factors can go on and on, With AI, however, we could develop an accurate model that would take all of these factors into account, and continue to refine its results season after season.
Overcoming the Challenge of Analyzing Large Drone Maps and Visualizing Results
The size of the drone maps used in any drone project poses a significant challenge in terms of storage and analysis. Traditional phone or camera images are typically much smaller and easier to work with. However, drone maps ranges from several hundred megabytes to over 10GB in size, making them difficult to store and analyze.
To address this challenge, we developed a triple solution that allows us to visualize these large drone maps losslessly in the web, train and validate custom models on this dataset, and make the recommendation engine simple and intuitive to use.
Here are some of the strategies we used to tackle the issue of large drone maps:
- We used a distributed file system that allows for the seamless transfer and storage of large files across multiple servers.
- We leveraged powerful cloud computing resources to process and analyze these large datasets.
- We developed a custom web-based platform that allows for the seamless visualization of these maps, as well as easy navigation and analysis of the data.
- We also implemented a range of image processing and compression techniques to optimize the storage and transfer of these large maps.
The Role of SwiftAI in Crop Mapping and Analysis
With the challenges we faced in traditional crop mapping and analysis methods, it became evident that we needed a more sophisticated system that could handle the uncertainty and variability of the avocado farm. This is where SwiftAI came in.
SwiftAI is an in-house AI product that has been developed by Swift Lab Limited to analyze crop aerial data. It is an advanced system that uses deep learning algorithms to identify and classify crop features from aerial images captured by drones. With SwiftAI, we were able to extract information from the images that traditional methods could not, such as crop count, line segmentation, gap analysis, crop health, weed detection, and forest species detection.
SwiftAI was trained on a large dataset of aerial images, and it has the ability to learn and adapt to new environments, making it ideal for analyzing crop data from different farms with varying conditions.
The use of AI in crop mapping and analysis is a game-changer for the agriculture industry in Kenya. With the ability to handle the uncertainty and variability of farms, AI can provide farmers with accurate and timely information, enabling them to make informed decisions that can improve crop yield and reduce costs.
Object Detection Results from PyTorch Code Run on the Dataset
- Mean Average Precision (mAP@0.5): Achieved a map50 value of 80%, indicating high accuracy in object detection. (Image: Graph of metrics/mAP(B) )
- Losses during Training: The training graph showed a steady decline in losses over time, indicating an effective training process. (Image: Graph of training losses)
- Recall: Achieved a recall value of 82%, meaning that the model was able to detect 82% of the objects in the dataset.
- Validation: The model was able to accurately detect objects in a validation dataset, achieving a mAP value of 85%.
Swift AI’s Recommendations
- SwiftAI analyzed and interpreted the large amount of data collected from the avocado farm.
- The AI system detected and segmented individual trees, counted the number of trees, estimated fruit yield, and identified different species of trees and their stage of growth.
- SwiftAI detected areas of low tree density and recommended planting new trees, identified potential disease or pest infestations, and provided information on optimizing pruning for better tree health and higher yields.
- The insights provided by SwiftAI helped the farm management team make data-driven decisions that led to higher yields and profits.
- The success of this proof of concept demonstrates the potential of AI in revolutionizing farming practices in Kenya and beyond.
Future of AI in Agriculture: Integration with IoT, Climate Data, and Yield Prediction
As our AI product, SwiftAI, continues to evolve, we are exploring new and exciting possibilities for its application. One area of interest is cereals, where SwiftAI could be used to predict crop yields and provide valuable insights to farmers.
Another area of exploration is climate data, where SwiftAI could analyze historical weather patterns and use that information to make predictions about future weather events. This could be invaluable for farmers in making decisions around planting times and irrigation.
Integration with IoT systems is another exciting area for SwiftAI. By connecting with sensors in the field, we can gather data on soil moisture levels, temperature, and other important factors. This data can then be analyzed by SwiftAI to provide farmers with real-time insights into the health of their crops.
Finally, we are also exploring the use of SwiftAI for yield prediction. By analyzing historical crop data, weather patterns, and other factors, we believe that we can develop a powerful tool for predicting yields and providing farmers with actionable insights for improving their yields.
Overall, we believe that the possibilities for SwiftAI are endless, and we are excited to continue exploring new areas for its application. By leveraging the power of AI, we can provide farmers with the tools they need to make informed decisions and maximize their crop yields.