Skip to content

Improve Readme documentation #2

@dcdenu4

Description

@dcdenu4

When trying out the container for a demo I ran into a few issues that I think would be really complicated for someone not familiar with Docker. I pulled the container and attempted to run my script, which takes command line input, like follows:

docker run --rm -ti -v %CD%:/natcap ghcr.io/natcap/devstack:latest python3 gef-rapid-es-assessments\scripts\landcover-transition\lulc-transition.py -f before-lulc.tif -t after-lulc.tif -o .\natcap\

This failed with:

python3: can't open file '/natcap/gef-rapid-es-assessments\\scripts\\landcover-transition\\lulc-transition.py': [Errno 2] No such file or dire

Then I tried this:

docker run --rm -ti -v %CD%:/natcap -w /natcap ghcr.io/natcap/devstack:latest python3 lulc-transition.py -f ../../../before-lulc.tif -t after-lulc.tif -o .\natcap\

This failed with:

ValueError: Could not open ../../../before-lulc.tif as a gdal.OF_RASTER

Finally, I put my command line inputs in the same place as the script and it worked successfully.

docker run --rm -ti -v %CD%:/natcap -w /natcap ghcr.io/natcap/devstack:latest python3 lulc-transition.py -f before-lulc.tif -t after-lulc.tif -o .\natcap\

So, it would be great to have better documentation about what each part of the docker command is doing and what is expected / assumed for running the script successfully.

I also wonder if we could be more flexible with the docker command.

Metadata

Metadata

Assignees

No one assigned

    Labels

    documentationImprovements or additions to documentation

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions