Brovey method and IHS method with weight
This commit is contained in:
@@ -17,6 +17,7 @@ var (
|
||||
outputDir string
|
||||
fusReport string
|
||||
fusMethod int
|
||||
weight float32
|
||||
)
|
||||
|
||||
var fusCmd = &cobra.Command{
|
||||
@@ -41,7 +42,8 @@ var fusCmd = &cobra.Command{
|
||||
|
||||
err := fusion.Pansharpen(panImage, mssImage,
|
||||
filepath.Join(outputDir, fusedTiff),
|
||||
fusion.PansharpenMethod(fusMethod))
|
||||
fusion.PansharpenMethod(fusMethod),
|
||||
weight)
|
||||
if err != nil {
|
||||
logrus.Fatal(err)
|
||||
}
|
||||
@@ -66,7 +68,8 @@ func init() {
|
||||
fusCmd.Flags().StringVarP(&mssImage, "mss", "m", "", "path to the MSS image")
|
||||
fusCmd.Flags().StringVarP(&outputDir, "output", "o", "", "path to the output directory")
|
||||
fusCmd.Flags().StringVarP(¶msXML, "params", "x", "", "path to the XML file containing parameters for GDAL_Pansharpen")
|
||||
fusCmd.Flags().IntVarP(&fusMethod, "method", "t", int(fusion.ESRI), "method to use for fusion (5: IHS, 3: ESRI)")
|
||||
fusCmd.Flags().IntVarP(&fusMethod, "method", "t", int(fusion.ESRI), "method to use for fusion (5: IHS, 3: ESRI 1: brovey)")
|
||||
fusCmd.Flags().Float32VarP(&weight, "weight", "w", 0.1, "weight of the MSS image in the fusion (0-1)")
|
||||
}
|
||||
|
||||
func initFUSParams() {
|
||||
|
||||
Reference in New Issue
Block a user