Smart Agriculture Cloud Using AI Based Techniques

: This research proposes a generic smart cloud-based system in order to accommodate multiple scenarios where agriculture farms using Internet of Things (IoTs) need to be monitored remotely. The real-time and stored data are analyzed by specialists and farmers. The cloud acts as a central digital data store where information is collected from diverse sources in huge volumes and variety, such as audio, video, image, text, and digital maps. Artiﬁcial Intelligence (AI) based machine learning models such as Support Vector Machine (SVM), which is one of many classiﬁcation types, are used to accurately classify the data. The classiﬁed data are assigned to the virtual machines where these data are processed and ﬁnally available to the end-users via underlying datacenters. This processed form of digital information is then used by the farmers to improve their farming skills and to update them as pre-disaster recovery for smart agri-food. Furthermore, it will provide general and speciﬁc information about international markets relating to their crops. This proposed system discovers the feasibility of the developed digital agri-farm using IoT-based cloud and provides solutions to problems. Overall, the approach works well and achieved performance efﬁciency in terms of execution time by 14%, throughput time by 5%, overhead time by 9%, and energy efﬁciency by 13.2% in the presence of competing smart farming baselines.


Introduction
The introduction should briefly place the study in a broad context and highlight why it is important. Food requirements are heavily dependent on agriculture and its quality of production. There is a large number of countries in the world where agriculture makes a large contribution to their economies. The populous countries such as Pakistan, India, China, etc., have a major portion of their land devoted to agriculture which not only fulfills their own needs but also provide handsome foreign return [1]. Currently, the integration of agriculture with internet technologies has contributed value addition to traditional farming. Similarly, the advent of the Internet of Things (IoT) in the agriculture sector has changed traditional farming to smart farming. Using cloud computing service models for storing and accessing agriculture data from multiple sources has greatly impacted the performance in the offline and real-time environment [2,3]. This performance in the cloud is measured by multiple factors such as response time, execution time, overhead time, migration time, optimization time, and energy consumption by computing resources [4]. Similarly, smart farming, with the help of IoTs, is using powerful machine learning models to access and disseminate the data in an efficient manner from and to the end-users such as farmers, advisors, and researchers. There is a strong need to process real-time information accurately so that an appropriate decision can be made in a timely manner by the end-users. This is only possible with the inclusion of strong machine learning models, such as the Support Vector Machine (SVM), in the cloud environment for efficient information processing. Some machine learning algorithms such as Cat Swarm Optimization (CSO) are more suitable for small population sizes with a minimum number of iterations and, hence, do not provide good solutions in a situation where the processing involves a large number of complex tasks. This drawback eventually leads CSO to fall into local optimum, which takes more iterations in finding solution spaces and, hence, renders CSO computationally complex. Therefore, we used SVM by introducing a new grouping phase process that takes the data files into four groups (audio, video, image, and text) taken from the SVM, keeping in view the properties associated with each group.
Cloud computing is a type of internet computing in which users may access programs via a browser while the application (together with the data) is installed and kept on a server. This is a whole new type of computing that allows thousands of farmers all over the world to access information without having to download or install anything on their computers or mobile phones. It enables mobility in the same way that most networks allow users to connect even if they do not have their computers, allowing them to work from anywhere in the world as long as they have an internet connection and access to a computer. Sensor technologies, personal mobile devices, wireless broadband connections, and cloud computing are allowing agriculturists and regular farmers to collect and disseminate agricultural data in real-time from anywhere. Personal mobile devices, such as Personal Digital Assistant (PDA)s and cellphones, are becoming more capable in terms of processing and information management, and they play an increasingly important part in people's everyday lives. This technical progress has led us to develop a scalable and cost-effective real-time agricultural monitoring and analysis system for those who need to monitor their farms regularly [5]. The focus will be on the design features of an autonomous cloud environment that collects farmer's agricultural data and distributes it to a cloud-based information repository, as well as facilitating data analysis by utilizing cloud-based software applications.
The consideration of this research work is to create a cloud computing infrastructure that will connect different agriculture resources to a central data store. The services may be in the form of information/responses to different queries raised by the farmers; automatic suggestions to farmers from time to time to improve their farming skills; provide specific slots in lands where the problem exists in multiple formats; automatically update the farmers on which crop is suitable in their area based on various factors; provide special features to farmers where they can also interact with local and world-leading agriculturists; update the farmers as pre-disaster recovery; and provide general and specific information about international markets relating to their crops. The data collected by the concerned providers will be sent to the data cloud store via an underlying computerized system, where it will be accessible to all connected farmers, advisors, researchers, and support centers. There are several activities to be performed by the developed system such as acquiring, managing, and using agricultural information from farms to enhance the quality and efficiency of farms and to respond to widespread public farmers queries. In particular, at the automated farm level, agriculture envisions that "a new system of distributed computing tools will collect authorized data about farm illness and store it securely within a network designed to help deliver quick and efficient care". Furthermore, the concepts, such as wearable agriculture devices, Farm Area Networks (FANs), pervasive wireless broadband communications, and cloud computing, are enabling advanced mobile farmcare services that benefit both farmers and agriculture professionals [6]. This enables the development of a system to perform remote real-time collection, dissemination, and analysis of farm data to manage chronic conditions and to detect farm emergencies. Our goal is to offer an architecturally generic cloud-based system that can be used in a variety of scenarios where farms need to be remotely monitored and recorded data have to be processed by a computer system and made available for professionals or farmers to access. Despite the fact that our designs and prototypes are flexible enough to suit a variety of use cases, we focus on one particular motivated case: The monitoring of farms affected by chemicals and sickness, which necessitates constant episode detection. Electrocardiogram data from commonly available wearable sensors are collected in real-time and utilized to detect and classify episodes.
This research study develops crop stress indicator models that provide data filter and alert capabilities for monitoring local agricultural conditions and provides an immediate solution to farmers as a remedy. Secondly, by taking the information service demand of "Three Rural Issues" in our country into consideration, we propose a cloud service platform for the information service in the countryside which can enable data sharing, remote data storage, interaction with farmers, agriculture expert consultation, and peasant household management. We want to provide a platform for the farmers with the answers to the following generalized question: How do our agricultural activities increase the yield or deliver higher efficiency with quality? As agriculture goes high-tech, our proposed agricultural technology revolution will not require farmers to put down their hoes and pick up a mouse. Instead, we predict the growth of specialist project groups with expertise in agricultural and associated disciplines, such as ecosystems [7]. Those who demand continual monitoring but live distantly from their service provider and find it impossible to attend frequent pesticides sessions will appreciate the value of a ubiquitous agricultural information system. Accordingly, it has been declared that the implemented approach has no adverse effect on the natural environment, social security, damage to human health, safety to biodiversity, pollution to physical, biological, hydrological resources, damage to public comfort, vegetal canopy, and other adverse environmental effects.
The following are the contributions of this research: • Agricultural data received in the cloud are classified into different file formats such as audio, video, text, images, and maps files; • File format classification is an innovative approach in smart farming that has never been adopted and, hence, contributed to the theory of science; • Multi-format files are processed by using SVM one-to-many types of machine learning methods in order to achieve efficiency in the cloud; • An AGRICLOUD (Agriculture Cloud) approach has achieved maximum accuracy with less response time, low overhead, and high throughput in the presence of a certain state of the art; • Importantly, the farmer achieves the supervisory level so that decisions can easily be taken by him.
The rest of this research study is organized as follows: A literature review is presented in Section 2, the proposed methodology is discussed in Section 3, results are explored in Section 4, and discussions are elaborated in Section 5. Finally, Section 6 concludes the work and identifies the future directions.

Materials Literature Review
Cloud computing is a new paradigm of computing in which dynamically scalable and often virtualized resources are referred to as clouds and are provided as a service over the internet [8]. Users of these services do not need any knowledge to construct them, maintain them, or to control the technology infrastructure used to construct these "clouds" that support them. Cloud computing technology is forcing a paradigm shift from owing the information and communication infrastructure to leasing it, allowing "cloud systems" to penetrate the market as an infrastructure in which services can be orchestrated. Cloud computing has emerged as a novel way for large-scale aggregation of various IT services provided through fast digital networks, similar to the electrical grid of public utilities [9,10]. The rise of cloud computing is rapidly changing the landscape of information technology and ultimately turning the long-held promise of utility computing into a reality [11,12].
Cloud computing's emergence has had a significant impact on the Information Technology (IT) industry in recent years, with companies such as Google, Amazon, and Microsoft contending to provide more powerful, reliable, and cost-effective cloud platforms. More businesses are reshaping their business models to take advantage of this evolving field [13,14]. There are several advantages of the cloud computing paradigm over traditional IT services on the following basis.
Minimum infrastructure investment cost: A cloud service user can simply rent the resources from different clouds, and the users only pays for the resources they have used according to some pricing model.
Minimum operating cost: A cloud service provider can dynamically allocate and de-allocate resources according to system usage situation at peak loads, which allows significant savings relative to the operational cost of resources when the usage of the system is low.
Scalability: A cloud service provider can easily extend its services by provisioning a larger amount of resources and making them accessible. The current IT technologies are not matured enough to realize the full potential of cloud computing technology [15]. Major challenges that arise in the implementation of cloud computing technology, including automatic resource provisioning, security management, and power management, are recieving attention from the research community. Therefore, researchers in this area still have tremendous opportunities to make novel contributions and bring about significant impact with respect to IT Industry.
Keeping in view the importance of cloud computing in the agriculture sector, several innovations have made inevitable the transition from traditional farming to smart farming in the world. Developing countries, such as Pakistan, need massive efforts to uplift their major source of revenue in the form of smart agriculture. To meet the food needs of Pakistan, continued population growth in Pakistan and the growing reliance on agriculture to provide replacements for fossil fuels mean that there are no alternatives but to begin smart and high-tech farming; all this simply amounts to using cloud computing to improve agricultural reforms.
Subsequently, farmers in rural and remote areas do not have similar access to intensive specialist support as in urban areas. Thus, there is a need to develop such a system that provides farmers with equal access to specialist support. Higher temperatures, increased agricultural water demand, more variable rainfall, and extreme climatic events such as heatwaves, floods, and droughts all have an impact on agriculture [16]. Farmers are the most vulnerable to climate change, but they can also play an important part in combating it by seizing opportunities.
Our proposed solution will investigate the above-mentioned problems for the benefit of the community at large. It would assist the farmers by providing a variety of possible options and also recommending the best solution based on many factors stored in a cloud of agricultural records in a timely and more efficient manner. The agricultural record includes a variety of types of "notes" entered over time by agriculturists and professionals from all over the world, including recording observations and the administration of pesticides, orders for the drugs, test results, scanning farms, reports, futuristic issues after natural disasters to lands, etc. The maintenance of a complete and accurate agricultural record is a fundamental requirement for any agriculturist and is generally enforced as a licensing or certification prerequisite.
Cloud Computing technology provides a pervasive means of efficiently sharing educational material and knowledge among institutions in a relatively low-cost manner in order to leverage the cooperative and sharing culture of higher education [17]. Collaboration between researchers, students, degree programs, and even administrative services is both a requirement and a driver for a true knowledge-based economy [18]. Cloud computing enables cost-effective collaboration across research-intensive institutions throughout the country and around the world, especially in the sciences, where large-scale equipment has become the standard. Scientists from diverse universities can share supercomputers, libraries can share digital humanities collections, astronomers can share galactic pictures, and network engineers may share strands of fiber in the same physical cable thanks to cloud computing technologies. In the same way, cloud computing is making a shifting paradigm by strengthening its roots in the agriculture sector. By establishing collaboration of scientists all over the world in the diverse field of agriculture, the end users can obtain maximum advantage in solving the number of problems with efficient solutions. This is only possible with the adoption of a cloud that relies not only on scientists but also takes into account other stakeholders such as farmers, advisors, local agriculture counselors, and students researching the same domain.
The current research study in smart agriculture is more focused on processing relevant information in a much shorter period of time. This includes the shortest response time in accessing the relevant information, the low overhead of the communication, lightweight protocol development for the execution time, and secure transmission of the critical information. To cater to such multiple QoS mentioned above, cloud computing is taking advantage of various machine learning models due to their established authenticity in many applications. One of the widely used machine learning models is SVM for making accurate classifications of data files. In the proposed agriculture model, the cloud would have a huge volume and variety of data taken from multiple sources such as IoTs, Zigbee, Wireless Sensor Network (WSN)s, etc. These data are securely stored in the cloud and will be updated continuously upon receiving information from farmers, scientists, advisors, and researchers. A variety of data in multi-formats such as audio, video, image, text, and maps are taken in real-time and stored in the cloud where SVM is used to classify them in respective classes. This would help in the accurate classification of the data files, which will be fed into Virtual Machines (VMs) for processing. In order to further improve efficient processing, one-to-many classification types of SVM are used. The process would be made radially available for the end-users for a prompt decision about multiple cases. An SVM model represents training data as points in space which are then separated into categories by a wider gap. The classifier then finds the hyperplane that differentiates two classes, and then it is categorized according to the gap they belong to. Furthermore, SVMs are effective in high dimensional spaces and in instances where the amount of dimensions is larger than the number of samples, and it is also memory efficient because it uses a subset of training data in the decision function which are called the support vectors. SVM treats one class at a time (e.g., text class) as a positive class and three other classes (audio, video, and image) as negative classes. Therefore, other classes are taken separately, in the same manner, using one-to-many classification properties of SVM. Some recent research studies taken from the literature are listed in Table 1, with some detail of their technique, their advantages, and disadvantages. Our designed method tries to minimize the limitations of the following research and proposes a comprehensive solution for an efficient agriculture cloud. In addition to the multi-format data classification approach using SVM, the proposed solution would curtail execution time in executing the query and generating the response to be received by the end-user. Another parameter is the reduction in throughput time of the system and minimization of the overhead of the proposed system. The developed system is then tested against some state-of-the-art baselines, and it is found that AGRICLOUD is performing better in a number of scenarios. The system proposes classification method for the detection of plant diseases Basic functionality is achieved A number of parameters need to be added for better classification

Methodology
This section may be divided into subheadings. The data stored in the cloud computing environment are available to all agriculture advisors, researchers, and farmers. The advisors can extract agriculture data about farms applying the same pesticides and analyze the treatment suggested by other agriculturists and experts that helps improve decisions. Furthermore, it is observed that sudden pest attacks are always referred to as uncontrollable when expert treatments are obtained. However, to reach out towards experts when in critical condition is not easy, and as a result the whole crop becomes destroyed. The proposed approach facilitates the advisors/farmers working in rural areas to discuss problem cases with experts in real-time and to treat these advisors/farmers in a better way. The overall functionality of the analysis and monitoring system includes the steps below:

1.
Farms are trained with a wireless sensor attached to specific points and a cellular device that is efficient enough to communicate through the Internet; 2.
The module of the wireless sensor collects the farm's data and sends it to the mobile device via Bluetooth without user intervention; 3.
A software of the client in the mobile device exhibits and transmits data to the analysis web service that is hosted by a cloud computing-based software. This interaction can occur with the mobile's data connectivity (e.g., mobile 4G/5G network), a home wireless gateway, or directly; 4.
The analysis software carries out several computations over the collected data by taking reference from the current demographic data and the farm's historic data.
Computations concern comparison, classification, and systematic diagnoses of farm lines, which can be time-consuming especially when it is performed for longer periods and for a large number of farmers; 5.
The software then extends the latest results to the historic record provided in private and secure cloud-based storage so that verified users can gain access to it anytime and from any place. Agriculturists then understand and translate the features extracted from the data, and a decision is made accordingly; 6.
The results in the form of advice are disseminated to the farmer's mobile device; 7.
The computing and monitoring processes are repeated daily/hourly, corresponding to the user's choice.
The proposed architecture is divided into three layers, such as the acquisition layer, the application layer, and the information exchange layer, as shown below in Figure 1.
device via Bluetooth without user intervention; 3. A software of the client in the mobile device exhibits and transmits data to the analysis web service that is hosted by a cloud computing-based software. This interaction can occur with the mobile's data connectivity (e.g., mobile 4G/5G network), a home wireless gateway, or directly; 4. The analysis software carries out several computations over the collected data by taking reference from the current demographic data and the farm's historic data. Computations concern comparison, classification, and systematic diagnoses of farm lines, which can be time-consuming especially when it is performed for longer periods and for a large number of farmers; 5. The software then extends the latest results to the historic record provided in private and secure cloud-based storage so that verified users can gain access to it anytime and from any place. Agriculturists then understand and translate the features extracted from the data, and a decision is made accordingly; 6. The results in the form of advice are disseminated to the farmer's mobile device; 7. The computing and monitoring processes are repeated daily/hourly, corresponding to the user's choice.
The proposed architecture is divided into three layers, such as the acquisition layer, the application layer, and the information exchange layer, as shown below in Figure 1.

Acquisition Layer
The acquisition layer comprises various sensors used to collect data installed at different locations. The data received in data collecting devices are of numerous formats such

Acquisition Layer
The acquisition layer comprises various sensors used to collect data installed at different locations. The data received in data collecting devices are of numerous formats such as audio, video, images, maps, texts, etc. In order to perform timely computation and to reduced overhead, there is a need to implement the classification of data of those types.
For the development of cloud platform of the agriculture sector, it is important to implement steps such as the creation of an information model, understanding the ontologies, understanding the data, cataloging the data, building information model based on collection information, building service model, creating service model, understanding services, building service model, creating process model, understanding processes, converting services to processes, building process model, creating a governance model, define-design-implement policies, testing cloud architecture, creating a test plan with black and white box testing, selecting platform-deploy-processes-services-data, and assigning candidate data-services-processes.

Information Exchange Layer
The information exchange layer is responsible for sharing the data from the acquisition layer to the application layer through the datacenter and runtime information.
The role of a classifier is to establish which class, among a set of different classes, an unknown object belongs. A classifier has to find the best boundaries between the different classes. The optimal classifier, called SVM, minimizes the total cost. They are based on the separating hyperplane. If the data have high enough dimensionality, the different classes, which constitute different clusters, are linearly separable by hyperplanes.
An SVM model represents training data as points in space, which are then separated into categories by a wider gap. The classifier then finds the hyperplane that differentiates two classes and then it is categorized according to the gap they belong to. Furthermore, SVMs are effective in high dimensional spaces and in instances where the amount of dimensions is larger than the number of samples, and it is also memory efficient because it uses a subset of training data in the decision function which are called the support vectors. The kernel trick permits dealing with non-linear separating surfaces since the data, initially in the input space, are transposed in a higher dimensional space where a separating hyperplane is found. Figure 1 illustrates this principle.
We have divided the VMs into four types of sets, such as Audio VM, Video VM, Text VM, and Image VM based on input data. Each set of VM has different processing and storage resources in a cloud environment. More precisely, each machine (VM) is assigned a task based on task requirements. For example, video tasks require 1000 floating-point operations and 16 Giga Byte (GB) memory, audio tasks require 800 floating-point operations and 12 GB memory, image tasks require 800 floating-point operations, and 8 GB memory, textual tasks require 400 floating-point operations, and 4 GB memory. For video data classification, we extracted feature vectors of sequences of 40 frames extracted from four different video classes, where we have a 40 × 4096 matrix and where each row refers to features of one frame (one frame per row). Thus, we classified videos between these four different classes. We preprocessed a new video to limit its number of frames and then extracted features from this video to classify it. Assume that we have four video classes (ci, i = 1, . . . , 4). Each video has 40 (n = 1, . . . , 40) frames and from each frame we extracted 4096 features (1 × 4096). Since each frame has enough information to predict the video class (ci), we used 40 frames from each video as training/test samples, which creates an input matrix of (160 × 4096) dimensions, with 160 samples and each sample have 4096 features. Additionally, we have created an output vector (160 × 1) that contains the label of each class ci = i, where i = 1, . . . , 4. The feature sets include low-level signal properties, mel-frequency spectral coefficients, and two new sets based on perceptual models of hearing. For image classification, we have considered 256 × 256 pixels (total of 65,536 pixels). We used each pixel as a feature in the SVM classifier. For text classification, there are text documents of about 6 GB which are extracted in the form of unstructured text. We performed stemming and stopped word removal and extracted the words in the form of features. We then used these features for text data classification using SVM. The deep learning models require more time to train and their convergence time is greater, as compared to SVM; thus, so this is why we have adapted the traditional machine learning approach [30].
One of the problems of cloud task scheduling is assigning jobs to various VMs to accomplish load balancing in the shortest time. The benefit is that cloud resources are better used and users' requests are met more quickly. One of the major machine learning techniques is the Support Vector Machine (SVM), proved as a powerful model for achieving accurate classifications if carefully performed. In this case, we are proposing one-to-many types of SVM so that one type of data is taken as the positive class at a time and the other three classes are taken as the negative class [15]. For example, in the first case, audio data are classified from the rest of the data classes, then video data, image, map, and video data are classified separately. This preprocessing is performed within the cloud, which results in saving computations later in the information exchange phase. In one-to-many types of classification using SVM, multiple classes are separated from one another. A few of the examples include an email folder containing different categories such as work, family, and students. We have a classification problem in which four classes are used with assigning numbers, such as workshop x1 = 1, family matters x2 = 2, customers orientation x3 = 3, and students behavior x4 = 4. In binary classification, one class is taken as positive, and the rest of the classes are taken as negative. Here, the idea of the one vs. all classification is taken to obtain the best accuracy results since this study involves four training sets with class 1 video data type as z1 = 1, class 2 text data type as z2 = 2, class 3 audio data type as z3 = 3, and class 4 image data type as z4 = 4. The proposed method is to take one class at a time and to turn it into four separate binary classifications. In this case, class 1 is taken as a positive class with value 1 and the three other classes as a negative class with value 0. When we train the datasets, this will provide us with a decision boundary of one class with the rest of the classes. In simple words, in the first instance, video datasets are taken as positive classes and all others as negative classes. In the second instance, text datasets are taken as a positive class, and the rest are negative classes. In the third instance, audio datasets are taken as positive classes, whereas others are negative classes. Finally, in the last instance, images belong to the positive class, whereas all other datasets are taken as negative classes. To make the communication secure, the AES lightweight version of the protocol is suggested so that information at the time remains secure and cannot be changed by the attacker in any type of security active attack. This helps in achieving confidentiality, integrity, and authentication of the exchanged information even within the layers until the end-users.

Application Layer
The application layer is responsible for displaying the results to the end-users in the form of GUI. These results consist of schedule data.
Algorithm 1 describes the steps involved in the data partition and data scheduling process.

Algorithm 1. AGRIClOUD
Input: video, text, audio, digital maps from different cloud sources, number of virtual machines (VM) Output: Data class, Scheduled data 1.
for data classification do 2.
for each P(u, v) do 3.
for each Classification accuracy = M do 5.
Evaluate data accuracy 6.
if Number of iterations = N then 7.
return data class 9.
for load balancing do 10.
schedule data ← Assign data to each group (cluster) w.r.t virtual machine 11. end for 12.
return schedule data We used one of the simplest kernels. The space X corresponds to R N , and we assume patterns x in which most information can be represented by the dth order products of entries [x]j of x. These products are called monomials. Here, the vector of monomials is used to represent the feature space H, and the mapping itself represents Φ. One can easily show that the dot product in the feature space is simply the square of the dot product in the input space. The hyperfunction is as follows: where u i . is used for support vector, ∝ i is represented as Lagrange multiplier, and u j is known as the label of membership class (+1, −1) where n = 1,2,3, . . . N.

Results
To check the functionality of the proposed system, the CloudSim4.0 simulator developed by University of Melbourne, Australia is used at the cloud server. The CloudSim4.0 simulator [31] is devised to perform the working of the systems in the simulated form under different scenarios. We have set the following parameters for our proposed system.
Overall, 100,000 files are collected at run time in various formats such as audio, video, image, text, and maps. These files are of varying sizes from 0.1 MB to 1 GB. The configuration of data centers, their size, number of hosts, Random Access Memory (RAM) size, task size on disk, storage capacity, bandwidth, and power are shown in Table 2. The simulation is performed on a Core i9 Intel Quad-core system (by Intel Corporation, USA) with 16 GB RAM and 4 TB HDD. Data files numbering 100,000 after preprocessing using SVM classification have been divided into an equal number of audio, video, image, and texts formats shown in Table 3. This helps in further processing the data with low computation cost and high accuracy as mentioned in Table 4. Cloud computing is making significant contributions in extracting useful information when combined with data distribution techniques. There could be another choice, such as Spark in data distribution, which makes it easy for huge volumes and a variety of data with the help of load balancing approaches. However, we have designed a model with minimum hardware cost and information processing cost for a large amount of data. Although Apache Spark (developed by UC Berkeley, USA) may provide better running time, our basic objective was to design an optimized model using machine learning algorithms.   The confusion matrix in terms of accuracy, precision, recall, F-measure, G-mean, and (Area Under Curve) AUC is calculated for the baselines classifiers such as SVM-GA [32], MSVM [33], MULTICLASS (Multiple Class) [34], and ACOSVM (Ant Colony Optimization using Support Vector Machine) [35]. All these baselines have proved their performance against the number of algorithms in the literature. However, after performing preprocessing using SVM one-to-many types, our AGRICLOUD has performed extremely well and has shown better classification performance. This will help in the further minimization of execution time later in the completion phase that results in benefiting the end-user such as a farmer, researcher, adviser, or expert.

Discussion
The developed algorithm AGRICLOUD is compared with CLAYMIST (cloud enabled CMM index for smart agriculture monitoring system) [36] and MISSENARD [37] baselines in terms of execution time, throughput time, and overhead time. In the first case, execution time is demonstrated for all algorithms in Figure 2. The number of tasks in the form of audio, video, images, texts, and maps is executed gradually over 5, 10, 20, 50, 100, 500, and 1000 VMs. It can be observed that, from the very start, AGRICLOUD remains very stable in processing the tasks. However, at 100 and more VMs, more execution time is required, showing less performance, but its performance is still better than CLAYMIST and MISENARD. These two algorithms performed somehow equal to 500 VMs but gradually started to require more execution time, rendering them the worse choice. This shows that the proposed algorithm has better classification performance and scalability than others.    Figure 4 shows the overhead time taken by all baselines over a set of VMs. The lower the overhead, the faster the response time and the higher the execution time will be. All algorithms start well at the beginning with low tasks and a smaller number of VMs. The algorithms abruptly started to take more overhead time when it reaches 100. However, due to the earlier performance of the INDIGSOL for better execution and throughput time, the overhead time remains slow, showing better performance of the proposed algorithm. Overall, this would help in processing the data in the form of audio, video, text, images, and maps much faster for the end-users. The end-user would be able to receive critical information such as weather, temperature, climate change, pesticide information, crop production, water level, soil moisture, and several other factors timely and precisely and with accuracy. This information is stored in the cloud in the form of historical data that would be updated continuously with every packet of information. Furthermore, the information is beneficial to the advisors, experts, and especially to the farmers at their doorstep without any additional cost. Table 5 shows the statistical data of AGRICLOUD with different baselines.  Student's t-test is used to find out the significant difference between AGRICLOUD and two baselines. This test finds out the difference between two independent groups that help to determine whether the difference is actual or due to chance. It is shown that the p-value for execution time, overhead time, and throughput time for all baselines is greater than 0.01 significance level. Similarly, the t-value for all baselines is greater than 0.01, showing that a significant difference exists. Therefore, statistically, our proposed algorithm is better than other baselines as well.

Conclusions and Future Work
Pakistan, being an agricultural country with 70% land, needs to pay much focus on the adoption of new technologies concerning global practices. The motivation assists our farmers in becoming advanced at the supervisory level so that they can manage things appropriately with an understanding of the farms. There is a need to build the capacity of the farmers so that they interact with one another in addition to experts. Currently, no such mature work exists both in practice and at the infrastructure level. The cost of management is the most important consideration here. As a result, the scope has been limited to computer resources, such as storage, processing, and data transport.
A farm health monitoring system now uses a mobile phone's processing capability, integration with farm sensors, and internet access to alert farmers when the crop requires attention or even perform an automatic intervention, such as triggering the automatic release of drugs into the farm when necessary. We designed a cloud computing-based real-time agricultural monitoring and analysis system capable of assisting farmers in better managing their farms by decreasing or eliminating on-site consultations.
An AGRICLOUD is proposed to solve most of the aforementioned issues currently present in agriculture. The main goal of this research is to propose an innovative solution that performs file formatting in the cloud so that pre-processing of a huge volume and variety of files will be performed initially. This pre-processing will save time when resources are assigned to the virtual machines resulting in much-reduced execution time and energy consumption. This approach makes the solution viable, robust, and scalable as it has been tested with gradually more and more resources. It is important to mention that file formatting in the cloud for agricultural data is an innovative step in smart farming that contributes to the body of science. It is observed that in some current baselines, the proposed system performed well for a few parameters such as execution time, throughput time, and overhead time while reducing the energy.
The authors are residents of Pakistan where most of the land is agricultural and belongs to rural areas. Here, people have low income and require innovative technologies to improve their farming skills so that per capita income may increase. The Government of Pakistan has initiated few agricultural reforms in which smart farming is one of them. Initially, this study is a pilot test study and is implemented with only Pakistan climate factors considered due to the huge cost involved. However, this study will also be extended to other countries in the future.
In the future, we will work on critical factors of cloud-based agriculture such as priority-based farming, agriculture 5.0, precision agriculture, telematics, and data analytics by using artificial intelligence-based techniques. This would help in making optimal decisions by keeping in view the availability of a certain number of resources.