Plant The Future using Deep Learning

Download Full-Text PDF Cite this Publication

Text Only Version

Plant The Future using Deep Learning

Nasir Basha K1, M G N S Suma2, Kalasamudram Sai Premika3, M R Drithika4, Savitha P5

1,2,3,4Department of Computer Science and Engineering, Sir M Visvesvaraya Institute of Technology, Bangalore, India

5Faculty in Department of Computer Science and Engineering, Sir M Visvesvaraya Institute of Technology, Bangalore, India

Abstract – Trees restore our air supply by producing oxygen and absorbing carbon dioxide. The amount of oxygen generated by an acre of trees annually equals the amount of oxygen consumed by 18 people over the year. In cities, the majority of trees are being cut down for the construction of roads and bridges. The vehicle traffic is the root cause for these constructions. As we observe the traffic density of any area in a country is increasing continuously. This continuous growth demands more and more roads and Fly-overs for easier and faster transportation. But these constructions, in turn, demand the cutting down of roadside and/or nearby trees. As we know Deforestation is the root cause of all the pollution. In these cases, the cutting down of trees becomes mandatory. The roadside trees are most vulnerable to getting cut-down. This aim is used to predict the probability of roadside trees going to be cut down for the construction of roads and flyovers in a given area in the given time-period. The idea is divided into 3 stages. 1. Predicting the traffic density of a given area using Machine Learning techniques. 2. Getting the satellite images of the related area to find the number of trees going to cut down and the amount of oxygen produced by those trees. 3. Finding the suitable empty(government) / nonempty(private) land(s) using Deep Learning to plant the tree saplings suitable for that region. From this, we can plant the number of trees which are going to cut down in the next couple of years so that when they are finally cut down, the oxygen levels can be maintained by the already planted young trees.

Keywords- Machine Learning; Deep Learning; trees; Satellite Images; traffic density; construction; roads; bridges; deforestation; pollution;


    Since the beginning, trees have offered us two of lifes essentials, food, and oxygen. As we evolved, they granted additional necessities such as shelter, tools, and medicines. Their value continues to increase even today and more benefits of trees are being discovered and discussed as their role expands to satisfy the needs pertaining to our modern lifestyles.

    Trees bestow on our environment by providing the most essential element for living beings – oxygen, by improving the air quality, by climate refinement, by conserving water, preserving soil, and supporting many wildlife. During the process of photosynthesis, trees produce the oxygen we breathe and take in carbon dioxide. According to the Department of Agriculture of The United States, One acre of forest absorbs six tons of carbon dioxide and puts out four tons of oxygen. This is enough to meet the annual needs of

    18 people. Trees, shrubs, and turf also purify air by removing dust and absorbing other pollutants like nitrogen dioxide. carbon monoxide and sulfur dioxide. After trees obstruct the unhealthy particles, rain washes them to the ground.

    Deforestation is one of the most predominant issues that has received substantial attention in many different disciplines. As shown in previous studies, this phenomenon has a harsh impact on regional hydrology, large-scale climatic systems and long-term climatic systems, global biochemical cycles, and extinction of various animal species. Despite its seriousness, most countries do not have any detailed statistics on the extent of deforestation. In Mexico, authors have reported deforestation rates of 0.3-0.5% per annum. Also, one study estimated the deforestation rate to be about 0.3% and 0.9% per year for the tropical and temperate areas. This study showed that 84,000 of forest cover were destroyed between 1975 and 2000.

    So, ending deforestation is our best chance to solve the extreme climate changes and protect wildlife. Earlier, 30% of India was covered by forests but now it is decreased to 26.5%. The effects of deforestation are already visible in cities like Delhi and Bombay. And due to the rapid urbanization, Bengaluru, Hyderabad, and other densely populated cities are next in line. The decreased levels of oxygen in the environment can lead to thinning of the atmospheric layer thus allowing the greenhouse gases to enter the atmosphere. If this continues to happen each human being requires two oxygen cylinders to breathe every day.


    Abdalla M. El-Habil [1] in 2012, proposed that the multinomial logistic regression (MLR) model is used for categorical data analysis using a mathematical concept called logit, which is logarithms of odds. It is a statistical method for analysis of a dataset in which there is one independent variable or multiple independent variables that determine the outcome. It is used to predict a binary outcome (True / False

    ,1 / 0, Yes / No). This method considered 18 explanatory variables that had an influence on physical violence against children, and these are examined by the MLR model to calculate response variables and all explanatory variables related to make the primary model. Then we check the errors for explanatory variables and then we re-calculate the model excluding the error variables and find a new MLR model.

    Yann LeCun Et al[2] in 2015, proposed that the Deep Learning technique represents models that consist of multiple processing layers with multiple levels of data abstraction and is used to predict output for a given set of inputs. The most common form of deep learning is supervised learning, which is a deep learning task of interfering with a function from labeled training data. It computes a function to measure the error between output and the desired pattern of scores. Many Deep Learning applications use feedforward neural network architectures. Deep Learning applications use a transfer learning approach,

    it is a process which involves fine-tuning of a previously trained model. It also uses the network as a feature extractor. Abadi, Martín Et al [3] in 2015, proposed that TensorFlow is an interface for expressing ML algorithms. As a part of the Google brain project, dist.-belief is the first- generation scalable distributed training and inference system. Tensor flow is the next version of dist-belief. Tensor flow takes the computations described by a data flow model and maps them onto a large variety of distinct hardware platforms. A TensorFlow is composed of a directed graph, which contains a set of nodes. Users interact with TensorFlow by creating sessions. To execute tasks, a run

    module is used.

    Gregory Koch Et al [4] in 2015, proposed that One-shot learning is a technique to teach the machine to learn from the single data samples for each class and make accurate predictions. A convolutional neural network approach is used. Siamese nets were first launched in the early 1990s by LeCun and Bromley to solve signature verification as an image recognition problem. A Siamese neural network consists of two similar networks that accept different inputs but are connected by an energy function at the top.

    Joseph Redmon Et al [5] in 2016, proposed that YOLO is used to detect an object in image. Detection is even more complex than a classification problem, which can also recognize objects but doesnt tell you the location of the object in the image and it will not work for images that contain multiple objects. YOLO is a clever neual network for real-time object detection. It reformulated object detection as a single regression problem, straight from image pixels to bounding box coordinates and class probabilities. YOLO trains on full images and directly optimizes the performance of the detection. The features from the entire image are used by this network to predict each bounding box. When making predictions, YOLO reasons globally about the image. YOLO also gives a confidence score that tells how certain it is that the predicted bounding box actually encloses some object. This score tells only if the shape of the box is any good but doesnt say anything about what kind of object is in the box.

    Jose Hormese Et al [6] in 2018, proposed that an ANN with input and output as a complete image is too complex and consumes a lot of memory, that it will be difficult to represent and train neural networks with easily accessible computers. The problem has been defined as, finding if a pixel is part of the road, based on the color profile of the adjacent region of the pixel of interest. The input layer of the convolutional neural network is a 255 x 255 x 3 matrix which is a block from the satellite image, which is expected to have relevant data to find the central pixel of the block is part of a road or not.


    A System is developed which predicts the number of trees in danger in the upcoming future of the given area. Traffic density of 20 years is considered to forecast the future traffic density and satellite images from altitude 7000m are considered for object detection.

    Fig-1 specifies the block diagram of the system where the entire system is comprised of two main parts, one is Traffic density forecasting and the other Trees and Arable land detection.


        Traffic density for consecutive 20 years is considered for predicting the traffic in the upcoming future years. Synthetic data is generated which resembles the typical traffic density pattern of any area. This is explained in the following sections.


          The traffic data is created using 1Dimentional Perlin noise, which is a kind of gradient noise developed in 1983 Ken Perlin as a result of his frustration with the "machine- like" look of computer-generated imagery (CGI) at that time.

          Fig-2 describes the nature of synthetic data.

          The dataset consists of 100 columns and each column consists of 7304 rows. Columns represent areas under consideration, whereas each row represents traffic count/density of the day for 20 years, starting from Jan 1st of 2000 to Dec 31st of 2019.


    To accurately forecast the future traffic a deep learning model is trained on the synthetic data. A Keras sequential model is best suitable for our purpose. The model summary is given below

    Fig-3 describes the trained model summary.

    The input layer consists of 3 LSTM nodes, the next layer is a Bidirectional LSTM layer which consists of 6 nodes, the following is a dense layer with 10 nodes. The output layer consists of a single Dense node with a lambda layer to boost the output. Stochastic Gradient Descent optimizer with

    Huber loss function best serves the purpose to train the noisy time series data.

    Fig-4 describes the prediction on validation data.

    The model is predicting with 0.0966 as normalized MAE (Mean Absolute Error) or 274.25 as the normal MAE (Mean Absolute Error) on test data. Actual data are plotted in orange color and the predicted values in blue color.


        Trees and Arable land are two objects of interest. Google Earth images of Denmark country is collected to train the object detector. Yolo version3 model is trained on the collected images. It is explained in the following sections.


          Google Earth images as collected for 100 locations of Denmark country. For each location, 9 images are taken. Selenium is used to automate the process of collecting screenshots of Google images of the locations. The 9 images structure of each location is given as below

          Fig-5 describes the structure of aerial view images of the location.

          Each image is taken from an altitude of 7660m. Single image corresponds to a length of 241.32 m and breadth of 109.79m. The Total area of each image is 26494.522m2. Such a large area is treated for the purpose of construction. Adding up areas of all the 9 images, an area equal to 238450.70m2 is considered to process each location.


    All the collected screenshot images are labeled in the YOLO V3 format using the LabelImage tool. Darknet framework is used to train the YOLO model. The training took 9hrs to complete 4000 iterations. The model trained with average MSE (Mean Squared Error) of 7.879. Pretrained

    coco models weights are taken to further train for our

    tree_top and arable_land detections.



        The model is trained on traffic data for consecutive 20 years. Predictions can be made accurately for 5 years in the future. The training loss and MAE obtained are shown in the below diagram.

        Fig-6 show the plot of training loss and MAE vs iterations

        The traffic data has a positive trend with little noise. The model is able to learn this accurately.

        Fig-7 shows the predicted values in blue color and actual data from 2000 to 2019 in orange color.


        Yolo model is trained to detect two objects namely tree_top and arable_land. The model is detecting the two classes accurately with MSE of 7.879. It returns the coordinates of boxes where the objects are present. The total count of trees present in an image is calculated. To calculate the total arable land in an image, each box is multiplied by the scaling factor to get the actual area of the box/object on the ground. The scaling factor is found by dividing the actual length of the land by the length of the image sides. The formula is given as below.

        Fig-8 describes the formula to calculate total arable land. Here 241.32 is the actual length of the area in meters and 109.79 is the actual breadth of the area in meters.

        The object detection results are plotted on the image to visually see the results.

        Fig 9 shows the object detection results, arable land is marked in blue color and trees in white color.

        Another example image to show the accuracy of object detection.

        Safe distance to plant a tree is 3m so the total area calculated for planting is divided into 9m2 of smaller blocks to plant the tree saplings.


    The outcome of this project is a system that predicts the traffic density and in turn, the future construction which leads to finding the endangered trees and thus replanting them in a suitable arable land. We designed a model which can predict the construction depending on the traffic statistics in an area. Unlike the misleading promises of the government, we make a clear decision on how many trees to be replanted and where to plant those trees. Although this system produces a different perspective towards

    tackling deforestation it still faces a few issues with the implementation. The system can improve in the following ways:

        • Dataset gathering: We, due to the mere lack of access to the data of the Indian government, have taken up the data from Denmark. However, training the samples on country-specific data is very essential.

        • Arable Land detection: The current system detects the arable land from the available dataset as any land that is empty and not a road track. However, it would be more accurate to analyze the arable land- based on public and private property. This can only be achieved with further study of the data with the help of the government.


      The system does not promise the complete eradication of deforestation. We are considering only traffic density but all the factors responsible for urban planning and development such as cost of living, migration of people, employment opportunities need to be considered for more accurate prediction of constructions. However, it has the potential to overcome most of the effects of deforestation by planting the same number of trees which will get cut down. The integration of a social cause and deep learning can make it effective for many NGOs and many responsible bodies, to take a step further in this battle for nature. The subtle discrepancies in this system can be taken care of if given more reliable resources, but it opens a new avenue for a lot of research.


    1. El-Habil, Abdalla M. "An application on multinomial logistic regression model." Pakistan journal of statistics and operation research 8, no. 2 (2012): 271-291.

    2. LeCun, Yann, Yoshua Bengio, and Geoffrey Hinton. "Deep learning." nature 521, no. 7553 (2015): 436-444.

    3. Abadi, Martín, Ashish Agarwal, Paul Barham, Eugene Brevdo, Zhifeng Chen, Craig Citro, Greg S. Corrado, et al. "Tensorflow: Large-scale machine learning on heterogeneous distributed systems." arXiv preprint arXiv:1603.04467 (2016). K. Elissa, Title of paper if known, unpublished.

    4. Muhammad, Iqbal, and Zhu Yan. "SUPERVISED MACHINE LEARNING APPROACHES: A SURVEY." ICTACT Journal on Soft Computing 5, no. 3 (2015).

    5. Koch, Gregory, Richard Zemel, and Ruslan Salakhutdinov. "Siamese neural networks for one-shot image recognition." In ICML deep learning workshop, vol. 2. 2015.

    6. Simon, Annina, S. D. Mahima, S. Venkatesan, and D. R. Babu Ramesh. "An overview of machine learning and its applications." Int J Electr Sci Eng 1 (2016): 22-24.

    7. Redmon, Joseph, Santosh Divvala, Ross Girshick, and Ali Farhadi. "You only look once: Unified, real-time object detection." In Proceedings of the IEEE conference on computer vision and pattern recognition, pp. 779-788. 2016.

    8. Hormese, Jose, and Chandran Saravanan. "A Comparison of Convolutional Neural Network Architectures for Road Classification from Satellite Images." In 2018 International Conference on Inventive Research in Computing Applications (ICIRCA), pp. 354-359. IEEE, 2018.

    9. Ahmadi, Vahid. "Deforestation Prediction Using Neural Networks and Satellite Imagery in a Spatial Information System." arXiv preprint arXiv:1803.02489 (2018).

    10. Prevedello, Jayme A., Gisele R. Winck, Marcelo M. Weber, Elizabeth Nichols, and Barry Sinervo. "Impacts of forestation and deforestation on local temperature across the globe." PloS one 14, no. 3 (2019): e0213368.

    11. . Geethapriya. S, N. Duraimurugan, S.P. Chokkalingam. "Real-Time Object Detection With YOLO." International Journal of Engineering and Advanced Technology (IJEAT) ISSN: 2249 8958, Volume-8, Issue-3S, February 2019.

    12. Sholtanyuk, S. V. "Comparative Analysis of Neural Networking and Regression Models for Time Series Forecasting." Digital Transformation (2019).

Leave a Reply

Your email address will not be published. Required fields are marked *