Giter VIP home page Giter VIP logo

accuraccy's Introduction

MapBiomas Accuracy Source Code

This repository organizes the MapBiomas accuracy codes.

Requisites:

  • Python 3.7 or above

  • scikit-learn library for Python

  • R 3.6.2 o above

  • R Studio 1.1.2.5 or above

  • tidyverse , ggplot2 , stringr , reshape2 , shiny , htmlwidgets , highcharter and dplyr packages for R

Recommendations:

  • For Windows, install Miniconda - Python 3.7 or above and add it to the system variable PATH like:

    • PATH = C:\ProgramData\Miniconda3; C:\ProgramData\Miniconda3\Library\bin; C:\ProgramData\Miniconda3\Scripts;
  • Install scikit-learn library using conda install -c intel scikit-learn on system terminal (windows prompt)

How to use

1. Export reference and classification matrix from Google Earth Engine (GEE)

Copy and paste the code src/estimates_codes/1_export_gee_input.js on your GEE code editor and click on Run. After that, click on Task and run every task.

2. Getting Accuracy Assessment information with Python

Open your system terminal and run the following line like python3 src/estimates_codes/2_accuracy_estimates.py <INPUT_DIR> <OUTPUT_DIR>. Enter the directory address of the exported files as INPUT_DIR and the output files as OUTPUT_DIR. Sit in a comfortable chair, grab a book, a coffee and wait ... this process can take a while.

When the process ends, run the code 3_format_toShinny_for_Unix.sh (For Windows: 3_format_toShinny_for_Windows.bat) inside the output directory. This code prepares the file names and directory hierarchy for the Shiny reading format.

One last change needs to be made. Download the Sublime code editor, drag and drop all .CSV files from the lv1, lv2 and lv3 output directories, then press Ctrl + Shift + F and replace all the "NA" for NaN (without quotes).

3. Visualize accuracy information using R/Shiny

To visualize the accuracy information that you have process you need to:

  • Copy the directories lv1, lv2 and lv3 to the directory src/visualization_codes/integracao/
  • Open the src/visualization_codes/App.R code with RStudio
  • Click on Run App (at the top center of the screen)

accuraccy's People

Contributors

vieiramesquita avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.