GithubHelp home page GithubHelp logo

sonwyang / deepcropmapping Goto Github PK

View Code? Open in Web Editor NEW

This project forked from lab-ideas/deepcropmapping

0.0 1.0 0.0 31 KB

Official implementation of "DeepCropMapping: A multi-temporal deep learning approach with improved spatial generalizability for dynamic corn and soybean mapping".

License: GNU General Public License v3.0

Python 36.39% Jupyter Notebook 63.61%

deepcropmapping's Introduction

DeepCropMapping: A multi-temporal deep learning approach with improved spatial generalizability for dynamic corn and soybean mapping

This repository is the official implementation of DeepCropMapping: A multi-temporal deep learning approach with improved spatial generalizability for dynamic corn and soybean mapping.

Requirements

  • torch
  • numpy
  • pandas
  • scikit-learn
  • jupyter

The code has been tested in the following environment: Ubuntu 16.04.4 LTS, Python 3.5.2, PyTorch 1.2.0

Data

The preprocessed data (.npy files) for model training and evaluation is not directly provided here due to the large data volume. You can download raw Landsat Analysis Ready Data (ARD) from EarthExplore and raw Cropland Data Layer (CDL) from CropScape, then follow the code in the preprocessing folder to generate the .npy files. The raw Landsat ARD and CDL data should be stored in a new data folder that has the following structure (specific downloaded file names may change):

data
├── Site_A
│   ├── ARD
│   │   ├── 2015
│   │   │   ├── LC08_CU_018007_20150424_20181206_C01_V01_PIXELQA.tif
│   │   │   ├── LC08_CU_018007_20150424_20181206_C01_V01_SRB2.tif
│   │   │   └── . . .
│   │   ├── . . .
│   │   └── 2018
│   └── CDL
│       ├── CDL_2015_clip_20190409130240_375669680.tif
│       ├── . . .
│       └── CDL_2018_clip_20190409125506_12566268.tif
├── Site_B
├── . . .
└── Site_F

The preprocessed data should be stored in the preprocessing/out folder that has the following structure:

preprocessing/out
├── Site_A
│   ├── x-2015.npy
│   ├── y-2015.npy
│   ├── . . .
│   ├── x-2018.npy
│   └── y-2018.npy
├── Site_B
├── . . .
└── Site_F

Training and evaluation

  • The PyTorch implementation of DeepCropMapping (DCM) model is located in the models folder.
  • The utils folder contains some utilities that are used for data loading, normalization, training and evluation.

The specific training and evaluation process can be executed by running the .ipynb files in the experiments folder.

The hyperparameters for different sites in the paper are set as follows:

Hyperparameter Site A Site B Site C Site D Site E Site F
Dimension of LSTM hidden features 256 512 256 512 256 256
Number of LSTM layers 2 2 2 2 2 3

deepcropmapping's People

Contributors

zhuyue1026 avatar xiong-xg avatar

Watchers

James Cloos 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.