img_src = r"D:\work\ms.monina\wp5\kalmthoutse_heide\2007-07-02_ahs\mos\2007-07-02_ahs_kalmthoutse_heide_mosaic.img" loc_src = r"D:\work\ms.monina\wp5\kalmthoutse_heide\field\kalmthoutse_heide_releve_plots.shp" img_bad_src = r"D:\work\ms.monina\wp5\kalmthoutse_heide\2007-07-02_ahs\_info\2007-07-02_ahs_bad_bands.txt" cov_src = r"D:\work\ms.monina\wp5\kalmthoutse_heide\2007-07-02_ahs\_info\2007-07-02_ahs_mosaic_plot_coverage.txt" #factor = 1 / 10000. neighborhood = 6 #neighborhood_type = 'circle' if not 'loc_id_field' in locals(): loc_id_field = 'plot_id' if not 'img_bad_src' in locals(): img_bad_src = '' if not 'cov_src' in locals(): cov_src = '' if not 'factor' in locals(): factor = 1 if not 'neighborhood' in locals(): neighborhood = 1 if not 'neighborhood_type' in locals(): neighborhood_type = 'square' if not 'additional_attributes' in locals(): additional_attributes = list() se = SpectraExtractor(img_src, loc_src, tgt_dir) se.extract(loc_id_field, img_bad_src, cov_src, neighborhood, factor, additional_attributes, neighborhood_type) se.dump_spectra(include_bad_bands=False) #se.export_spectra()
loc_src = r"z:\fabi\wh_sample_pts.shp" #loc_src = r"D:\work\ms.monina\wp5\wahner_heide\field\shp\wh_195plots_doku_2009.shp" loc_id_field = 'id' additional_attributes = ['type'] #img_bad_src = r"D:\work\ms.monina\wp5\wahner_heide\2009-08-06_hymap\_info\2009-08-06_hymap_bad_bands.txt" #img_bad_src = r"D:\work\ms.monina\wp5\wahner_heide\2011-09-14_apex\_info\2011-09-14_apex_bad_bands.txt" #cov_src = r"D:\work\ms.monina\wp5\wahner_heide\2009-08-06_hymap\_info\2009-08-06_hymap_plot_coverage.txt" #factor = 1 / 10000. #neighborhood = 2 if not 'loc_id_field' in locals(): loc_id_field = 'plot_id' if not 'img_bad_src' in locals(): img_bad_src = '' if not 'cov_src' in locals(): cov_src = '' if not 'factor' in locals(): factor = 1 if not 'neighborhood' in locals(): neighborhood = 1 if not 'additional_attributes' in locals(): additional_attributes = list() se = SpectraExtractor(img_src, loc_src, tgt_dir) se.extract(loc_id_field, img_bad_src, cov_src, neighborhood, factor, additional_attributes) se.dump_spectra(include_bad_bands = True) se.export_spectra()
loc_src = r"Z:/fabi/wh_sample_pts.shp" #loc_src = r"D:\work\ms.monina\wp5\wahner_heide\field\shp\wh_195plots_doku_2009.shp" loc_id_field = 'id' additional_attributes = ['type'] img_bad_src = r"D:\work\ms.monina\wp5\wahner_heide\2009-08-06_hymap\_info\2009-08-06_hymap_bad_bands.txt" #cov_src = r"D:\work\ms.monina\wp5\wahner_heide\2009-08-06_hymap\_info\2009-08-06_hymap_plot_coverage.txt" factor = 1 / 10000. #neighborhood = 2 if not 'loc_id_field' in locals(): loc_id_field = 'plot_id' if not 'img_bad_src' in locals(): img_bad_src = '' if not 'cov_src' in locals(): cov_src = '' if not 'factor' in locals(): factor = 1 if not 'neighborhood' in locals(): neighborhood = 1 if not 'additional_attributes' in locals(): additional_attributes = list() se = SpectraExtractor(img_src, loc_src, tgt_dir) se.extract(loc_id_field, img_bad_src, cov_src, neighborhood, factor, additional_attributes) se.dump_spectra(include_bad_bands=True) se.export_spectra()
img_src = r"D:\work\ms.monina\wp5\doeberitzer_heide\2008-08-07_hymap\mos\2008-08-07_hymap_doeberitzer_heide_mosaic_good_bands_only.img" loc_src = r"D:\work\ms.monina\wp5\doeberitzer_heide\field\doeberitzer_heide_releve_plots.shp" # img_bad_src = r"D:\work\ms.monina\wp5\doeberitzer_heide\2008-08-07_hymap\_info\2008-08-07_hymap_bad_bands.txt" cov_src = r"D:\work\ms.monina\wp5\doeberitzer_heide\2008-08-07_hymap\_info\2008-08-07_hymap_strip_plot_id_linkage_duplicates_.txt" # factor = 1 / 10000. neighborhood = 2 # neighborhood_type = 'circle' if not "loc_id_field" in locals(): loc_id_field = "plot_id" if not "img_bad_src" in locals(): img_bad_src = "" if not "cov_src" in locals(): cov_src = "" if not "factor" in locals(): factor = 1 if not "neighborhood" in locals(): neighborhood = 1 if not "neighborhood_type" in locals(): neighborhood_type = "square" if not "additional_attributes" in locals(): additional_attributes = list() se = SpectraExtractor(img_src, loc_src, tgt_dir) se.extract(loc_id_field, img_bad_src, cov_src, neighborhood, factor, additional_attributes, neighborhood_type) se.dump_spectra(include_bad_bands=False) # se.export_spectra()