Django-large-image

Latest version: v0.10.0

Safety actively analyzes 622360 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

0.10.0

large-image` recently introduced a new `rasterio`-based source module which many users may find easier to use than the GDAL source module. The changes in this release make `django-large-image` compatible with the new `rasterio` source module and switch the testing/demo to use that module over GDAL.

0.8.0

New Features

Notable
- Major UI overhaul
- Copy metadata button
- Modern UI styling
- Advanced multi-band compositing with custom colors
- Connects `large-image`'s caching mechanisms to utilize the Django cache framework
- Specify the named cache as the `LARGE_IMAGE_CACHE_NAME`, otherwise uses the `'default'` cache
- New `tiffdump` endpoint utilizing tifftools to extract information from Tiff files
- Support for URI encoded styles in request URL parameters (documented in README)
- Improved internal mechanisms for opening tile sources for easier overrides downstream
- User can specify the source class to use through the `source` URL parameter
- Better format handing for endpoints that serve image data (single endpoint where `PNG`, `JPEG`, or `TIFF` are specified for the desired format)

Additional

- Support `max_width` and `max_height` specification for generating thumbnails
- Improvements to SSR template overriding
- mypy type annotations throughout API
- New `TileMetadataSerializer` for the `tiles/metadata` endpoint
- Improved API error handling
- Better OpenAPI RESTful arguments documentation



Demos

- Standalone Docker image demo app: https://github.com/girder/django-large-image/pkgs/container/django-large-image-demo
- Usage with [`django-raster`](https://github.com/geodesign/django-raster): https://github.com/ResonantGeoData/django-raster-demo
- Noted support for GeoDjango's `GDALRaster` in README
- Document how to convert Pyramidal Tiffs (COGs) with Celery tasks



Deprecations & Changes

- `internal_metadata` -> `metadata_internal`
- Metadata endpoints are now under the `info/` prefix
- e.g., `metadata` -> `info/metadata`
- Data endpoints are now under the `data/` prefix
- e.g., `thumbnail.png` -> `data/thumbnail.(?P<fmt>png|jpg|jpeg)`

0.4.0

*This release has breaking changes*

There are now 4 ViewSet mixin classes for use with both detail and non-detail viewsets in DRF.

The following are the provided mixin classes and their use case:

- `LargeImageMixin`: for use with a standard, non-detail `ViewSet`. Users must implement `get_path()`
- `LargeImageDetailMixin`: for use with a detail viewset like `GenericViewSet`. Users must implement `get_path()`
- `LargeImageFileDetailMixin`: (most commonly used) for use with a detail viewset like `GenericViewSet` where the associated model has a `FileField` storing the image data.
- `LargeImageVSIFileDetailMixin`: (geospatial) for use with a detail viewset like `GenericViewSet` where the associated model has a `FileField` storing the image data that is intended to be read with GDAL. This will access the data over GDAL's Virtual File System interface (a VSI path).

Most users will want to use `LargeImageFileDetailMixin`

Other changes:

- Style parameters can now be included as a JSON blob in the request body following the [format specified by large-image](https://girder.github.io/large_image/tilesource_options.html#style)
- The thumbnail, tile, and region endpoints now each have `.png`, `.jpeg`, and `.tif` variants where appropriate
- DRF `ValidationError`s are raised for user-caused API errors (return 400 status on endpoint)
- More usage examples

0.2.4

django-large-image is here to solve your image tile serving needs in Django! Take a look at the README for some example implementations and give it a try in your project with image data.

Highlights

- Easy to use mixin interface
- Rich set of RESTful endpoints to extract information from large image formats
- Serve image tiles in the slippy maps standard (`z/x/y.png`)
- Produce thumbnails of large images on the fly
- Works with `FileField` interfaces
- Works with URL files (through GDAL's VFS/VSI layer)
- Included viewer for admin interface or server-rendered templates
- OpenAPI documentation included


![admin](https://user-images.githubusercontent.com/22067021/161357272-c436ff8f-781d-4eeb-9c8c-b1b70898d927.png)

Links

Releases

Has known vulnerabilities

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.