Include "Subset Bands" within "Save as"

Issue #1056 new
Agustin Lobo created an issue

Currently, "Subset Bands" lets save in vrt format only. Having this tool as an option within “Save as” makes more sense.

Comments (12)

  1. Andreas Janz

    Hmm, not sure. The “big” tool, where you can do everything at ones is the “Translate raster layer”. Here you can change the format, subset bands, and do lot’s of other things.

    When band subsetting is part of “Save as”, why not also spatial subsetting, or data type conversion?

    I kind of understand, why you want that, but I’m not sure if this is a good thing.

  2. Agustin Lobo reporter

    Another command I was not aware of: “Translate layer”.

    Yes, in principle, there is no reason to have “Save as” or “Subset Bands” if all options are clearly in “Translate layer”. I recall this is the

    way it works in classic envi.

    Then I would just modify my request to having an optional box for “Exclude bad bands”in “Translate raster”, which would be faster than selecting bands. At least you can get rid of “Subset bands”.

    But also think that “Save as” is redundant with “Translate layer”. In fact, the “as” in “Save as” potentially implies a translation. I would eliminate the current “Subset bands” and “Save as” but would rename “Translate” as “Save as”.

  3. Andreas Janz

    Yes, in principle, there is no reason to have “Save as” or “Subset Bands” if all options are clearly in “Translate layer”

    “Translate raster layer” is quite a monster. It was a conscious decision to provide some light-weight algorithms for changing the file format (Save as) and for band subsetting.

  4. Andreas Janz

    Then I would just modify my request to having an optional box for “Exclude bad bands”in “Translate raster”, which would be faster than selecting bands

    That is already one of the many features 😉

  5. Andreas Janz

    But also think that “Save as” is redundant with “Translate layer”. In fact, the “as” in “Save as” potentially implies a translation. I would eliminate the current “Subset bands” and “Save as” but would rename “Translate” as “Save as”.

    “Save as” is really just for changing the file format, e.g. from GTiff to ENVI.

    “Translate raster layer” is really THE tool to do all kinds of conversions at ones, even reprojecting into a new pixel Grid. “Save as” isn’t reflecting that.

    Note that the term “Translate” originated in the GDAL Translate Tool:
    https://gdal.org/programs/gdal_translate.html

    Also note that we added the reprojection functiuonality you would get via the GDAL Warp Tool:
    https://gdal.org/programs/gdalwarp.html

  6. Agustin Lobo reporter

    “Translate raster layer” is quite a monster. It was a conscious decision to provide some light-weight algorithms for changing the file format (Save as) and for band subsetting.

    Not a monster if it is well structured. Anyway, I suggest merging “Save as” and “Subset Bands” to reduce redundancy.

  7. Agustin Lobo reporter

    That is already one of the many features

    Yes, just had seen it today with a fresher mind. I think it is out of place, this is not at all an “advanced feature” but something so common that you have thought to put in a specific tool. I suggest having this option in the same panel as where you select bands (“Select all”, “Select none”, “Select bad bands”).

  8. Andreas Janz

    I think it is out of place, this is not at all an “advanced feature” but something so common that you have thought to put in a specific tool.

    I’ll discuss with the team if this should be placed under “Advanced” or not.

    I suggest having this option in the same panel as where you select bands (“Select all”, “Select none”, “Select bad bands”).

    That would be nice, but technically not so easy, because I have no control over the subsetting widget (which is owned by QGIS processing framework).

  9. Andreas Janz

    I suggest merging “Save as” and “Subset Bands” to reduce redundancy.

    Will discuss this in the team.

  10. Agustin Lobo reporter

    Subset bands does not let the user select the output format, Save as does not let the user select bands…

  11. Andreas Rabe

    We discussed this in the team and decided to keep it as is.

    Note that to have all the functionalities in one algorithms, you can always use the “Translate raster layer” algo.

  12. Log in to comment