CSIP_Const.java [src/java/lamps] Revision: default  Date:
/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
package lamps;

import java.util.ArrayList;
import java.util.Date;
import java.util.List;

/**
 *
 * @author od
 */
public class CSIP_Const {

    public static final String CDL_LAYER_DIR = "/CropScape_CDL/";

    // georeferencing database, shapfiles with States & CMZs information
    public static final String USStatesshp = "GIS_analysis_data/USStates.shp";
    public static final String CMZshp = "GIS_analysis_data/CMZs.shp";
    public static final String USCountiesshp = "GIS_analysis_data/USCounties.shp";

    //USGS natonwide irrigation raster for 2002 and 2007; original 250m resolution, resampled to 50m
    public static final String Irrigation2002 = "GIS_analysis_data/irri02_50lzw.tif";
    public static final String Irrigation2007 = "GIS_analysis_data/irri07_50lzw.tif";
    public static final String Irrigation2012 = "GIS_analysis_data/irri12_30lzw.tif";
    public static final String Irrigation2017 = "GIS_analysis_data/irri17_30lzw.tif";

    //current result/output files
    public static final String AOI_NASS_dominant_result = "AOI_NASS_dominant_crop.csv";
    public static final String AOI_NASS_LMOD_result_custom = "AOI_NASS_LMOD_custom.csv";
    public static final String AOI_NASS_LMOD_generic_result = "AOI_NASS_LMOD_generic.csv";
    public static final String AOI_NASS_Plain_result = "AOI_NASS_plain.csv";
    public static final String AOI_LAMPS_CONF_result = "AOI_LAMPS_conf.csv";

    //current AGES result/output files
    public static final String AOI_AGESW_MANAGMENT = "management.csv";
    public static final String AOI_AGESW_HRUS_ROT = "hrus_rot.csv";
    public static final String AOI_AGESW_CROPROTATION = "croprotation.csv";
    public static final String AOI_AGESW_TILLAGE = "till.csv";

    //database file folder
    public static final String LocalDB = "/H2DB/test";

    public static final int currentNASSyear = 2023;

    //available years with accuracy values
    public static final String[] ACC_years = {"2008", "2009", "2010", "2011", "2012", "2013", "2014", "2015", "2016", "2017", "2018", "2019", "2020", "2021", "2022", "2023"};

    public static final String[] CDL_years = {"1997", "1998", "1999", "2000", "2001", "2002", "2003", "2004", "2005", "2006", "2007", "2008", "2009", "2010", "2011", "2012", "2013", "2014", "2015", "2016", "2017", "2018", "2019", "2020", "2021", "2022", "2023"};

    public static final double Accuracy_Delta = 0.15;

    //well-known text format with coordinate system for Albers Equal Area projection
    public static final String WKT_CooSyst = "PROJCS[\"NAD83 / BC Albers\","
            + "GEOGCS[\"NAD83\", "
            + "  DATUM[\"North_American_Datum_1983\", "
            + "    SPHEROID[\"GRS 1980\", 6378137.0, 298.257222101, AUTHORITY[\"EPSG\",\"7019\"]], "
            + "    TOWGS84[0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0], "
            + "    AUTHORITY[\"EPSG\",\"6269\"]], "
            + "  PRIMEM[\"Greenwich\", 0.0, AUTHORITY[\"EPSG\",\"8901\"]], "
            + "  UNIT[\"degree\", 0.017453292519943295], "
            + "  AXIS[\"Lon\", EAST], "
            + "  AXIS[\"Lat\", NORTH], "
            + "  AUTHORITY[\"EPSG\",\"4269\"]], "
            + "PROJECTION[\"Albers_Conic_Equal_Area\"], "
            + "PARAMETER[\"central_meridian\", -96.0], "
            + "PARAMETER[\"latitude_of_origin\", 23.0], "
            + "PARAMETER[\"standard_parallel_1\", 29.5], "
            + "PARAMETER[\"false_easting\", 0.0], "
            + "PARAMETER[\"false_northing\", 0.0], "
            + "PARAMETER[\"standard_parallel_2\", 45.5], "
            + "UNIT[\"m\", 1.0], "
            + "AXIS[\"x\", EAST], "
            + "AXIS[\"y\", NORTH], "
            + "AUTHORITY[\"EPSG\",\"3005\"]]";

    public static final String WKT_KML = "GEOGCS[\"WGS 84\",DATUM[\"WGS_1984\",SPHEROID[\"WGS 84\",6378137,298.257223563,AUTHORITY[\"EPSG\",\"7030\"]],AUTHORITY[\"EPSG\",\"6326\"]],PRIMEM[\"Greenwich\",0,AUTHORITY[\"EPSG\",\"8901\"]],UNIT[\"degree\",0.01745329251994328,AUTHORITY[\"EPSG\",\"9122\"]],AUTHORITY[\"EPSG\",\"4326\"]]";

    public static final List<String> NonFieldCropClasses = new ArrayList<>();

    static {
        NonFieldCropClasses.add("Open Water");
        NonFieldCropClasses.add("Perennial Ice/Snow");
        NonFieldCropClasses.add("Developed");
        NonFieldCropClasses.add("Developed/High Intensity");
        NonFieldCropClasses.add("Developed/Low Intensity");
        NonFieldCropClasses.add("Developed/Med Intensity");
        NonFieldCropClasses.add("Developed/Open Space");
        NonFieldCropClasses.add("Barren");
        NonFieldCropClasses.add("Deciduous Forest");
        NonFieldCropClasses.add("Evergreen Forest");
        NonFieldCropClasses.add("Forest");
        NonFieldCropClasses.add("Mixed Forest");
        NonFieldCropClasses.add("Shrubland");
        NonFieldCropClasses.add("Grassland Herbaceous");
        NonFieldCropClasses.add("Herbaceous Wetlands");
        NonFieldCropClasses.add("Clouds/No Data");
        NonFieldCropClasses.add("Christmas Trees");
        NonFieldCropClasses.add("Nonag/Undefined");
        NonFieldCropClasses.add("Other Crops");
        NonFieldCropClasses.add("Other Small Grains");
        NonFieldCropClasses.add("Grass/Pasture");
        NonFieldCropClasses.add("Pasture/Grass");
        NonFieldCropClasses.add("Pasture/Hay");
        NonFieldCropClasses.add("Other Hay/Non Alfalfa");
        NonFieldCropClasses.add("Other Tree Crops");
        NonFieldCropClasses.add("Wetlands");
        NonFieldCropClasses.add("Woody Wetlands");
        NonFieldCropClasses.add("no data");
        NonFieldCropClasses.add("NODATA");
        NonFieldCropClasses.add("Water");
    }

    public static final List<String> potential_weeds = new ArrayList<>();

    static {
        potential_weeds.add("Grassland Herbaceous");
        potential_weeds.add("Other Crops");
        potential_weeds.add("Other Small Grains");
        potential_weeds.add("Grass/Pasture");
        potential_weeds.add("Pasture/Grass");
        potential_weeds.add("Pasture/Hay");
        potential_weeds.add("Other Hay/Non Alfalfa");
    }

    public static final List<String> basic_non_crop_management_info = new ArrayList<>();

    static {
        basic_non_crop_management_info.add("@T, management");
        basic_non_crop_management_info.add("desc, management.csv");
        basic_non_crop_management_info.add(" ");
        basic_non_crop_management_info.add("# landuse management");
        basic_non_crop_management_info.add("# Date format 'MM-DD' ");
        basic_non_crop_management_info.add("# ID crop-ID referred to crop.csv");
        basic_non_crop_management_info.add("# Date when operation starts");
        basic_non_crop_management_info.add("# Till-id according to till.csv");
        basic_non_crop_management_info.add("# Fert-id according to fert.csv");
        basic_non_crop_management_info.add("# FAmount amount of fertilizer application [kg/ha] absolut");
        basic_non_crop_management_info.add("# Plant (1) assumes that planting operation; - no planting");
        basic_non_crop_management_info.add("# Harvest (1-4)assumes that plant is harvested; - no harvest");
        basic_non_crop_management_info.add("# for harvesting 4 codes are implemented:");
        basic_non_crop_management_info.add("# (1) assumes harvesting with main crop & cover crop, cover crop leaves the field, plant growth stopped");
        basic_non_crop_management_info.add("# (2) assumes harvesting with main crop cover crop remains on the field; plant growth stopped");
        basic_non_crop_management_info.add("# (3) assumes harvesting with main crop & cover crop; plant growth continues (may not be suitable for meadows)");
        basic_non_crop_management_info.add("# (4) assumes harvesting with main crop plant growth continues");
        basic_non_crop_management_info.add("# FracHarv is the fraction of the target biomass which will be removed by the harvest (according to harvest code)");
        basic_non_crop_management_info.add("# CID 27 spring wheat; 88 winter rape; 97 winter barley; 12 pasture; 7 Forrest-Deciduous; 98 urban; 8 Coniferous Forrest; 28 Winter-Wheat; 31Spring Barley; 20 Maize; 100 yellow Mustard; 16 Range-Brush; 18 Water");
        basic_non_crop_management_info.add("# MID: 0 Fallow; 1 Forrest-Deciduous; 2 Forrest-Coniferous; 3 Pasture; 4 Range-Grasses; 5 Range-Brush; 6 Water(not supported in AgES-W); 7 Urban Areas; ");
        basic_non_crop_management_info.add("# ");
        basic_non_crop_management_info.add("# " + new Date());
        basic_non_crop_management_info.add("# LAMPS provided information are starting with MID 10 ");
        basic_non_crop_management_info.add(" ");
        basic_non_crop_management_info.add("@H,MID,CID,Date,TID,FID,FAmount,PLANT,HARVEST,FRACHARV,Description");
        basic_non_crop_management_info.add(",1,1, 01-01,-,-,-,-,-,-,Fallow,");
        basic_non_crop_management_info.add(",1,1, 12-31,-,-,-,-,-,-,Fallow,");
        basic_non_crop_management_info.add(",2,7, 01-01,-,-,-,-,-,-,Forrest-Deciduous,");
        basic_non_crop_management_info.add(",2,7, 10-22,-,-,-,-,1,0.1,Forrest-Deciduous,");
        basic_non_crop_management_info.add(",2,7, 12-31,-,-,-,-,-,-,Forrest-Deciduous,");
        basic_non_crop_management_info.add(",3,8, 01-01,-,-,-,-,-,-,Forrest-Coniferous,");
        basic_non_crop_management_info.add(",3,8, 11-16,-,-,-,-,1,0.1,Forrest-Coniferous,");
        basic_non_crop_management_info.add(",3,8, 12-31,-,-,-,-,-,-,Forrest-Coniferous,");
        basic_non_crop_management_info.add(",4,12, 03-31,-,45,1125,-,-,-,Pasture,");
        basic_non_crop_management_info.add(",4,12, 06-29,-,-,-,-,1,0.9,Pasture,");
        basic_non_crop_management_info.add(",4,12, 07-09,-,21,100,-,-,-,Pasture,");
        basic_non_crop_management_info.add(",4,12, 10-27,-,-,-,-,1,0.9,Pasture,");
        basic_non_crop_management_info.add(",5,15, 01-01,-,-,-,-,-,-,Range-Grasses,");
        basic_non_crop_management_info.add(",5,15, 10-22,-,-,-,-,1,0.1,Range-Grasses,");
        basic_non_crop_management_info.add(",5,15, 12-31,-,-,-,-,-,-,Range-Grasses,");
        basic_non_crop_management_info.add(",6,16, 01-01,-,-,-,-,-,-,Range-Brush,");
        basic_non_crop_management_info.add(",6,16, 10-22,-,-,-,-,1,0.1,Range-Brush,");
        basic_non_crop_management_info.add(",6,16, 12-31,-,-,-,-,-,-,Range-Brush,");
        basic_non_crop_management_info.add(",7,18, 01-01,-,-,-,-,-,-,Water,");
        basic_non_crop_management_info.add(",7,18, 12-31,-,-,-,-,-,-,Water,");
        basic_non_crop_management_info.add(",8,98, 01-01,-,-,-,1,-,-,Urban Areas,");
        basic_non_crop_management_info.add(",8,98, 12-31,-,-,-,-,1,-,Urban Areas,");
        basic_non_crop_management_info.add(",9,1, 01-01,-,-,-,1,-,-,Agricultural Land-Generic,");
        basic_non_crop_management_info.add(",9,1, 12-31,-,-,-,-,1,0.9,Agricultural Land-Generic,");
    }

    public static final Integer MID_Start = 10;

    public static final List<String> basic_non_crop_tillage_info = new ArrayList<>();

    static {
        basic_non_crop_tillage_info.add("@T, till");
        basic_non_crop_tillage_info.add("name, till.csv");
        basic_non_crop_tillage_info.add("descr, default tillage input parameters");
        basic_non_crop_tillage_info.add("# tillage information");
        basic_non_crop_tillage_info.add("# " + new Date());
        basic_non_crop_tillage_info.add("# TID = Tillage ID");
        basic_non_crop_tillage_info.add("# tillnm = Tillage name");
        basic_non_crop_tillage_info.add("# desc = description");
        basic_non_crop_tillage_info.add("# effmix = efficiency soil mixing fraction");
        basic_non_crop_tillage_info.add("# deptil = Tillage depth in mm");
        basic_non_crop_tillage_info.add("# LAMPS provided information are starting with TID 79 ");
        basic_non_crop_tillage_info.add(" ");
        basic_non_crop_tillage_info.add("@H,TID,tillnm,desc,effmix,deptil");
        basic_non_crop_tillage_info.add(",1,FALLPLOW,GENERIC FALL PLOWING OPERATION,0.95,150");
        basic_non_crop_tillage_info.add(",2,SPRGPLOW,GENERIC SPRING PLOWING OPERATION,0.5,125");
        basic_non_crop_tillage_info.add(",3,CONSTILL,GENERIC CONSERVATION TILLAGE,0.25,100");
        basic_non_crop_tillage_info.add(",4,ZEROTILL,GENERIC NO-TILL MIXING,0.05,25");
        basic_non_crop_tillage_info.add(",5,DUCKFTC,DUCKFOOT CULTIVATOR,0.55,100");
        basic_non_crop_tillage_info.add(",6,FLDCULT,FIELD CULTIVATOR,0.3,100");
        basic_non_crop_tillage_info.add(",7,FUROWOUT,FURROW-OUT CULTIVATOR,0.75,25");
        basic_non_crop_tillage_info.add(",8,MARKER,MARKER (CULTIVATOR),0.45,100");
        basic_non_crop_tillage_info.add(",9,ROLLCULT,ROLLING CULTIVATOR,0.5,25");
        basic_non_crop_tillage_info.add(",10,ROWCULT,ROW CULTIVATOR,0.25,25");
        basic_non_crop_tillage_info.add(",11,DISCOVAT,DISCOVATOR,0.5,25");
        basic_non_crop_tillage_info.add(",12,LEVELER,LEVELER,0.5,25");
        basic_non_crop_tillage_info.add(",13,HARROW,HARROW (TINES),0.2,25");
        basic_non_crop_tillage_info.add(",14,CULMULCH,CULTI-MULCH ROLLER,0.25,25");
        basic_non_crop_tillage_info.add(",15,CULPKPUL,CULTI-PACKER PULVERIZER,0.35,40");
        basic_non_crop_tillage_info.add(",16,LANDLEVL,LAND PLANE-LEVELER,0.5,75");
        basic_non_crop_tillage_info.add(",17,LANDALL, LANDALL DO-ALL,0.3,150");
        basic_non_crop_tillage_info.add(",18,LASRPLAN,LASER PLANER,0.3,150");
        basic_non_crop_tillage_info.add(",19,LEVPLDIS,LEVEE-PLOW-DISC,0.75,25");
        basic_non_crop_tillage_info.add(",20,FLOAT,FLOAT,0.1,60");
        basic_non_crop_tillage_info.add(",21,FLDCDSCR,FIELD COND (SCRATCHER),0.1,60");
        basic_non_crop_tillage_info.add(",22,LISTRMID,LISTER (MIDDLE-BUSTER),0.15,40");
        basic_non_crop_tillage_info.add(",23,ROLLGROV,ROLLER GROOVER,0.25,60");
        basic_non_crop_tillage_info.add(",24,ROLPKRAT,ROLLER PACKER ATTACHMENT,0.05,40");
        basic_non_crop_tillage_info.add(",25,ROLPKRFT,ROLLER PACKER FLAT ROLLER,0.35,40");
        basic_non_crop_tillage_info.add(",26,SANDFIGT,SAND-FIGHTER,0.7,100");
        basic_non_crop_tillage_info.add(",27,SEEDROLL,SEEDBED ROLLER,0.7,100");
        basic_non_crop_tillage_info.add(",28,CRUSTBST,CRUST BUSTER,0.1,60");
        basic_non_crop_tillage_info.add(",29,ROLLHRRW,ROLLER HARROW,0.4,60");
        basic_non_crop_tillage_info.add(",30,TRIPLE K,TRIPLE K,0.4,100");
        basic_non_crop_tillage_info.add(",31,FINHARRW,FINISHING HARROW,0.55,100");
        basic_non_crop_tillage_info.add(",32,FLEXHARW,FLEX-TINE HARROW CL,0.2,25");
        basic_non_crop_tillage_info.add(",33,SPIKETTH,POWERED SPIKE TOOTH HARROW,0.4,75");
        basic_non_crop_tillage_info.add(",34,SPIKTOTH,SPIKE TOOTH HARROW,0.25,25");
        basic_non_crop_tillage_info.add(",35,SPRGTOTH,SPRINGTOOTH HARROW,0.35,25");
        basic_non_crop_tillage_info.add(",36,SOILFINS,SOIL FINISHER,0.55,75");
        basic_non_crop_tillage_info.add(",37,ROTHOE,ROTARY HOE,0.1,5");
        basic_non_crop_tillage_info.add(",38,ROTERRA,ROTERRA,0.8,5");
        basic_non_crop_tillage_info.add(",39,ROTOTILL,ROTO-TILLER,0.8,5");
        basic_non_crop_tillage_info.add(",40,ROTBEDDR,ROTOVATOR-BEDDER,0.8,100");
        basic_non_crop_tillage_info.add(",41,ROWBUCK,ROWBUCK,0.7,100");
        basic_non_crop_tillage_info.add(",42,RIPPER,RIPPER,0.25,350");
        basic_non_crop_tillage_info.add(",43,MIDBST1R,MIDDLE BUSTER,0.7,100");
        basic_non_crop_tillage_info.add(",44,RODWEEDR,ROD WEEDER,0.3,25");
        basic_non_crop_tillage_info.add(",45,RUBWHWPL,RUBBER-WHEEL WEED PULLER,0.35,5");
        basic_non_crop_tillage_info.add(",46,MULTIWDR,MULTI-WEEDER,0.3,25");
        basic_non_crop_tillage_info.add(",47,MLDBOARD,MOLDBOARD PLOW,0.95,150");
        basic_non_crop_tillage_info.add(",48,CHISPLOW,CHISEL PLOW,0.3,150");
        basic_non_crop_tillage_info.add(",49,CCHPLOW,COULTER-CHISEL PLOW,0.5,150");
        basic_non_crop_tillage_info.add(",50,DISKPLOW,DISK PLOW,0.85,100");
        basic_non_crop_tillage_info.add(",51,STUBMLCH,STUBBLE-MULCH PLOW,0.15,75");
        basic_non_crop_tillage_info.add(",52,SUBCHPLW,SUBSOIL CHISEL PLOW,0.45,350");
        basic_non_crop_tillage_info.add(",53,ROWCOND,ROW CONDITIONER,0.5,25");
        basic_non_crop_tillage_info.add(",54,HIPPER,HIPPER,0.5,100");
        basic_non_crop_tillage_info.add(",55,RICEROLL,RICE ROLLER,0.1,50");
        basic_non_crop_tillage_info.add(",56,PARAPLOW,PARAPLOW,0.15,350");
        basic_non_crop_tillage_info.add(",57,SBEDHIPR,SUBSOILER-BEDDER HIP-RIP,0.7,350");
        basic_non_crop_tillage_info.add(",58,RIPRSUBS,DEEP RIPPER- SUBSOILER,0.25,350");
        basic_non_crop_tillage_info.add(",59,VRIPPER,V-RIPPER,0.25,350");
        basic_non_crop_tillage_info.add(",60,BEDROLLR,BED ROLLER,0.25,50");
        basic_non_crop_tillage_info.add(",61,BEDDER D,BEDDER (DISK),0.55,150");
        basic_non_crop_tillage_info.add(",62,BEDDHIPR,BEDDER DISK-HIPPER,0.65,150");
        basic_non_crop_tillage_info.add(",63,BEDDKROW,BEDDER DISK-ROW,0.85,100");
        basic_non_crop_tillage_info.add(",64,BEDDER S,BEDDER SHAPER,0.55,150");
        basic_non_crop_tillage_info.add(",65,DSKBRMKR,DISK BORDER MAKER,0.55,150");
        basic_non_crop_tillage_info.add(",66,DKCHMTIL,DISK CHISEL (MULCH TILLER),0.55,150");
        basic_non_crop_tillage_info.add(",67,OFFSETHV,OFFSET DIS/HEAVDUTY,0.7,100");
        basic_non_crop_tillage_info.add(",68,OFFSETLT,OFFSET DIS/LGHTDUTY,0.55,100");
        basic_non_crop_tillage_info.add(",69,ONE-WAYT,ONE-WAY (DISK TILLER),0.6,100");
        basic_non_crop_tillage_info.add(",70,TANDEMPL,TANDEM DISK PLW,0.55,75");
        basic_non_crop_tillage_info.add(",71,TANDEMRG,TANDEM DISK REG,0.6,75");
        basic_non_crop_tillage_info.add(",72,SINGLDIS,SINGLE DISK,0.45,100");
        basic_non_crop_tillage_info.add(",73,PWRMULCH,POWER MULCHER,0.7,50");
        basic_non_crop_tillage_info.add(",74,BLADE 10,BLADE 10 FT,0.25,75");
        basic_non_crop_tillage_info.add(",75,FURWDIKE,FURROW DIKER,0.7,100");
        basic_non_crop_tillage_info.add(",76,BEETCULT,BEET CULTIVATOR,0.25,25");
        basic_non_crop_tillage_info.add(",77,CLTIWEED,CULTIWEEDER,0.3,100");
        basic_non_crop_tillage_info.add(",78,PACKER,PACKER,0.35,40");
    }

    public static final Integer TID_Start = 79;

    public static final List<String> basic_croprotation_info = new ArrayList<>();

    static {
        basic_croprotation_info.add("@T, rot");
        basic_croprotation_info.add("name, croprotation.csv");
        basic_croprotation_info.add("descr, crop rotation input parameter");
        basic_croprotation_info.add("# crop rotation information");
        basic_croprotation_info.add("# " + new Date());
        basic_croprotation_info.add("# RID = Rotation ID");
        basic_croprotation_info.add("# MID = Management ID");
        basic_croprotation_info.add("# LAMPS provided information");
        basic_croprotation_info.add(" ");
        basic_croprotation_info.add("@H,RID,MID");
    }
    public static final List<String> basic_hrurotation_info = new ArrayList<>();

    static {
        basic_hrurotation_info.add("@T, rot_hru");
        basic_hrurotation_info.add("name, hrus_rot.csv");
        basic_hrurotation_info.add("descr, hru rotation input parameter");
        basic_hrurotation_info.add("# hru rotation information");
        basic_hrurotation_info.add("# " + new Date());
        basic_hrurotation_info.add("# ID = HRU or Field ID or polygon ID");
        basic_hrurotation_info.add("# RID = Rotation ID");
        basic_hrurotation_info.add("# REDU = Reduction switch for nitrogen modul");
        basic_hrurotation_info.add("# IRRI = LAMPS detected Irrigation (1 detected / 0 not detected)");
        basic_hrurotation_info.add("# landuseID = generic landuse ID for the landuseID in the HRUs.csv file");
        basic_hrurotation_info.add("# LAMPS provided information");
        basic_hrurotation_info.add(" ");
        basic_hrurotation_info.add("@H,ID,RID,REDU,IRRI,landuseID");
    }
}