Package: osml-tile-server
OversightML Tile ServerThe OversightML Tile Server (TS) is a lightweight, cloud-based tile server which allows you to quickly pass an image from S3 bucket to get metadata, image statistics, and set of tiles in real-time.Table of ContentsGetting StartedPackage LayoutPrerequisitesRunning Tile Server LocallySupport & FeedbackSecurityLicenseGetting StartedPackage Layout/src: This is the Python implementation of this application./test: Unit tests have been implemented usingpytest./doc: Contains Sphinx Doc configuration which is used to generate documentation for this package/load-test: Contains sampleLocustconfiguration files which is used to run load test against the Tile ServerDocumentationAPIs: You can find API documentation for the OSML Tile Server hosted on ourGitHub project page. Keep in mind that theTry it outbutton functionality does not work in Github project page.Alternatively, if you are working from the source code running docker build, you can find the latest API documentation by booting up the Tile Server by visitinghttp://0.0.0.0:8080/latest/docsorhttp://0.0.0.0:8080/latest/redoc. With this approach, you can useTry it outfunctionality.PrerequisitesFirst, ensure you have installed the following tools locallydockerdocker composetoxCloning the repositoryClone the repository to your local computer usinggit clone https://github.com/aws-solutions-library-samples/osml-tile-server.gitNavigate to the cloned directory usingcdordir, depending on your operating system.More information about cloning and managing repositories can be found in theGitHub Docs.Building the InfrastructureTile Server infrastructure is contained in theassociated CDK repository,
and a sample can be deployed by following the instructions in theGuidance for Overhead Imagery Inference on AWS repository.Running Tile Server LocallyThe Tile Server is designed to be able to be run locally using docker compose for development and testing purposes
using docker compose.Note: Some operating systems may usedocker-composeinstead ofdocker compose.Configure yourAWS credentialsfor the account in which the Tile Server infrastructure was deployed by setting your environment variables.export AWS_DEFAULT_REGION=<region where TS infrastructure deployed in>
export AWS_ACCESS_KEY_ID=<AKIAIOSFODNN7EXAMPLE>
export AWS_SECRET_ACCESS_KEY=<wJalrXUtnFEMI/K7MDENG/bPxRfiCYEXAMPLEKEY>Start the Tile Server usingdockercomposeup-dTo view the live log output while the server is runningdockerlogs-fosml-tile-serverTo stop the tile serverdockercomposedownTo rebuild the docker image after making a code change, usedockercomposeup-d--buildIn another terminal to invoke the rest server and return the viewpoint on a single image, run the following command:curl-X'POST'\'http://localhost:8080/latest/viewpoints/'\-H'accept: application/json'\-H'Content-Type: application/json'\-d'{"bucket_name": "<S3 Bucket>","object_key": "<Image Name>","viewpoint_name": "test","tile_size": 512,"range_adjustment": "NONE"}'Additionally, you can head over to FastAPI homepage and be able to execute various of API calls by visitinghttp://0.0.0.0:8080/latest/docs or http://0.0.0.0:8080/latest/redocSupport & FeedbackTo post feedback, submit feature ideas, or report bugs, please use theIssuessection of this GitHub repo.If you are interested in contributing to OversightML Model Runner, see theCONTRIBUTINGguide.SecuritySeeCONTRIBUTINGfor more information.LicenseThis library is licensed under the MIT-0 License. See theLICENSEfile.