{"id":23957,"library":"large-image","title":"large-image","description":"A Python library for working with large, multiresolution images, supporting tiles, annotations, and warping. Current version is 1.34.1, with regular releases every few weeks.","status":"active","version":"1.34.1","language":"python","source_language":"en","source_url":"https://github.com/girder/large_image","tags":["large-image","multiresolution","tiles","annotations","histopathology"],"install":[{"cmd":"pip install large-image","lang":"bash","label":"Install core library"},{"cmd":"pip install large-image[sources]","lang":"bash","label":"Install with all optional source formats"}],"dependencies":[{"reason":"Used for image array operations","package":"numpy","optional":false},{"reason":"Used for basic image I/O","package":"Pillow","optional":false},{"reason":"Optional Girder integration for server-side image serving","package":"girder","optional":true},{"reason":"Optional support for SVS/OME-TIFF via OpenSlide","package":"openslide-python","optional":true},{"reason":"Optional support for TIFF files","package":"tifffile","optional":true}],"imports":[{"note":"Use the unified 'source' API instead of per-format modules.","wrong":"import large_image_source_tiff","symbol":"source","correct":"from large_image import source"},{"note":"The main entry point is 'getTileSource' from the top-level package.","wrong":"from large_image_source_tiff import getTileSource","symbol":"getTileSource","correct":"from large_image import getTileSource"}],"quickstart":{"code":"from large_image import getTileSource\n\n# Open an image (replace with a path to a large image)\nsource = getTileSource('path/to/large_image.svs')\nprint('Image metadata:', source.getMetadata())\n\n# Get a tile (x, y, z) - e.g., tile at top-left of level 0\ntile = source.getTile(0, 0, 0)\nprint('Tile shape:', tile.shape)\n\n# Get a region (format: {'left', 'top', 'right', 'bottom'})\nregion = source.getRegion(region={'left': 0, 'top': 0, 'right': 256, 'bottom': 256})\nprint('Region shape:', region.shape)","lang":"python","description":"Opens a multiresolution image and retrieves a tile and a region."},"warnings":[{"fix":"Use getRegion with pixel coordinates if you need arbitrary rectangular crops.","message":"Tile coordinates (x, y, z) are integer tile indices, not pixel coordinates. Use getRegion for pixel-based cropping.","severity":"gotcha","affected_versions":"<1.34.0"},{"fix":"Use `from large_image import source` or `getTileSource` directly.","message":"The `large_image_source_tiff` and other per-format modules are deprecated in favor of the unified `source` API.","severity":"deprecated","affected_versions":">=1.0"},{"fix":"Install with the appropriate extras: `pip install large-image[openslide,tiff]`.","message":"When installed without optional dependencies (e.g., OpenSlide, tifffile), unsupported image formats will raise an ImportError.","severity":"gotcha","affected_versions":"all"}],"env_vars":null,"last_verified":"2026-05-01T00:00:00.000Z","next_check":"2026-07-30T00:00:00.000Z","problems":[{"fix":"Install OpenSlide system package (e.g., apt install openslide-tools) and then `pip install openslide-python`.","cause":"Missing OpenSlide native library or Python binding.","error":"ModuleNotFoundError: No module named 'openslide'"},{"fix":"Use `from large_image import getTileSource` instead of instantiating a class.","cause":"Incorrect import of legacy class name.","error":"AttributeError: module 'large_image' has no attribute 'LargeImageSource'"}],"ecosystem":"pypi","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}