### Get Inverse Transformation using ~ Operator Source: https://context7.com/rasterio/affine/llms.txt Demonstrates how to obtain the inverse of an Affine transformation using the '~' operator. It also shows how applying a transform followed by its inverse returns the original coordinates and handles degenerate transforms that cannot be inverted. ```python from affine import Affine from affine import TransformNotInvertibleError # Get inverse transform trans = Affine.translation(10, 20) inv_trans = ~trans print(inv_trans.xoff, inv_trans.yoff) # -10.0 -20.0 # Round-trip transformation rot = Affine.rotation(37.0) point = (12, 5) transformed = rot @ point recovered = ~rot @ transformed print(f"Original: {point}, Recovered: ({recovered[0]:.6f}, {recovered[1]:.6f})") # Verify inverse relationship combined = Affine.translation(3, 4) @ Affine.rotation(37.0) identity_check = ~combined @ combined print(identity_check.is_identity) # True # Handle degenerate transforms (cannot be inverted) degenerate = Affine.scale(0) # Collapses everything to origin try: ~degenerate except TransformNotInvertibleError as e: print(f"Cannot invert: {e}") ``` -------------------------------- ### Apply Affine Transformations to Coordinates in Python Source: https://github.com/rasterio/affine/blob/main/README.rst Shows how to apply an affine transformation matrix to a 2D coordinate tuple (x, y) to get the transformed coordinates (x', y'). This is done using the multiplication operator. ```python from affine import Affine # Define a translation matrix trans_matrix = Affine.translation(1.0, 5.0) # Apply the translation to a point (1.0, 1.0) print(trans_matrix * (1.0, 1.0)) # Define a rotation matrix rot_matrix = Affine.rotation(45.0) # Apply the rotation to a point (1.0, 1.0) print(rot_matrix * (1.0, 1.0)) ``` -------------------------------- ### Create Affine Transformation Matrices Source: https://github.com/rasterio/affine/blob/main/docs/src/index.md Demonstrates creating various affine transformation matrices using class methods like identity, translation, scale, shear, and rotation. These methods allow for convenient composition of transformations. ```python from affine import Affine # Identity matrix print(Affine.identity()) # Translation matrix print(Affine.translation(1.0, 5.0)) # Scale matrix print(Affine.scale(2.0)) # Shear matrix (in decimal degrees) print(Affine.shear(45.0, 45.0)) # Rotation matrix (in decimal degrees) print(Affine.rotation(45.0)) ``` -------------------------------- ### Create Affine Transforms in Python Source: https://context7.com/rasterio/affine/llms.txt Demonstrates how to create Affine transformation matrices in Python using direct coefficient input or predefined class methods like identity. It shows how to access matrix elements and offsets. ```python from affine import Affine # Direct construction with coefficients (a, b, c, d, e, f) # Matrix form: # | x' | | a b c | | x | # | y' | = | d e f | | y | # | 1 | | 0 0 1 | | 1 | t = Affine(1, 2, 3, 4, 5, 6) print(t.a, t.b, t.c) # 1.0 2.0 3.0 print(t.d, t.e, t.f) # 4.0 5.0 6.0 print(t.xoff, t.yoff) # 3.0 6.0 (aliases for c and f) # Identity transform (no transformation) identity = Affine.identity() # Affine(1.0, 0.0, 0.0, # 0.0, 1.0, 0.0) ``` -------------------------------- ### Apply Scale Transforms in Python Source: https://context7.com/rasterio/affine/llms.txt Illustrates creating and applying scaling transformations, both uniform and non-uniform, using the Affine library in Python. It also demonstrates flipping/mirroring using negative scale factors. ```python from affine import Affine # Uniform scaling (same factor for both axes) scale_uniform = Affine.scale(2.0) print(tuple(scale_uniform)[:6]) # (2.0, 0.0, 0.0, 0.0, 2.0, 0.0) # Non-uniform scaling (different factors) scale_xy = Affine.scale(3, 0.5) # scale x by 3, y by 0.5 point = (10, 20) print(scale_xy * point) # (30.0, 10.0) # Flip/mirror using negative scale flip_x = Affine.scale(-1, 1) # Mirror across y-axis flip_y = Affine.scale(1, -1) # Mirror across x-axis print(flip_x * (5, 3)) # (-5.0, 3.0) ``` -------------------------------- ### Create Affine Transformation Matrices in Python Source: https://github.com/rasterio/affine/blob/main/README.rst Demonstrates how to create various affine transformation matrices using the Affine class methods. This includes identity, translation, scaling, shearing, and rotation. ```python from affine import Affine # Create an identity matrix print(Affine.identity()) # Create a translation matrix print(Affine.translation(1.0, 5.0)) # Create a scale matrix print(Affine.scale(2.0)) # Create a shear matrix (in decimal degrees) print(Affine.shear(45.0, 45.0)) # Create a rotation matrix (in decimal degrees) print(Affine.rotation(45.0)) ``` -------------------------------- ### Affine Instance Methods Source: https://github.com/rasterio/affine/blob/main/docs/src/index.md Methods that operate on an existing Affine transformation object. ```APIDOC ## Affine Instance Methods ### `almost_equals(other: Affine, precision: float | None = None) -> bool` Compare transforms for approximate equality. **Parameters** - `other` (Affine) - Transform being compared. - `precision` (float | None) - Precision to use to evaluate equality. **Returns** - bool - True if absolute difference between each element of each respective transform matrix < `precision`. ### `itransform(seq: MutableSequence[Sequence[float]]) -> None` Transform a sequence of points or vectors in-place. **Parameters** - `seq` (MutableSequence[Sequence[float]]) - Mutable sequence of points or vectors. **Returns** - None - The input sequence is mutated in-place. ### `to_gdal() -> tuple[float, float, float, float, float, float]` Return same coefficient order expected by GDAL’s SetGeoTransform(). **Returns** - tuple[float, float, float, float, float, float] - Ordered: c, a, b, f, d, e. ### `to_shapely() -> tuple[float, float, float, float, float, float]` Return affine transformation parameters for shapely’s affinity module. **Returns** - tuple[float, float, float, float, float, float] - Ordered: a, b, d, e, c, f. ``` -------------------------------- ### Combine Affine Transformations Source: https://github.com/rasterio/affine/blob/main/docs/src/index.md Illustrates how to combine multiple affine transformations by multiplying their respective matrices. The order of multiplication determines the order of transformations. ```python from affine import Affine translation_matrix = Affine.translation(1.0, 5.0) rotated_matrix = Affine.rotation(45.0) # Combine translation and rotation combined_transform = translation_matrix * rotated_matrix print(combined_transform) ``` -------------------------------- ### Compute Inverse Affine Transformation Source: https://github.com/rasterio/affine/blob/main/docs/src/index.md Demonstrates how to compute the inverse of an affine transformation matrix using the tilde `~` operator. This is useful for reversing transformations, such as converting world coordinates back to image coordinates. ```python from affine import Affine geotransform = (-237481.5, 425.0, 0.0, 237536.4, 0.0, -425.0) forward_transform = Affine.from_gdal(*geotransform) # Compute the inverse transform reverse_transform = ~forward_transform col, row = 0, 100 original_coords = (col, row) # Apply forward and then reverse transform to verify transformed_coords = forward_transform * original_coords reverted_coords = reverse_transform * transformed_coords print(reverted_coords) ``` -------------------------------- ### Affine Class Methods Source: https://github.com/rasterio/affine/blob/main/docs/src/index.md Methods for creating new Affine transformation objects. ```APIDOC ## Affine Class Methods ### `from_gdal(c: float, a: float, b: float, f: float, d: float, e: float) -> Affine` Use same coefficient order as GDAL’s GetGeoTransform(). **Parameters** - `c`, `a`, `b`, `f`, `d`, `e` (float) - Parameters ordered by GDAL’s GeoTransform. **Returns** - Affine ### `identity() -> Affine` Return the identity transform. **Returns** - Affine ### `permutation(*scaling: float) -> Affine` Create the permutation transform. For 2x2 matrices, there is only one permutation matrix that is not the identity. **Parameters** - `*scaling` (float) - Ignored. **Returns** - Affine ### `rotation(angle: float, pivot: Sequence[float] | None = None) -> Affine` Create a rotation transform at the specified angle. **Parameters** - `angle` (float) - Rotation angle in degrees, counter-clockwise about the pivot point. - `pivot` (Sequence[float] | None) - Pivot point coordinates to rotate around. If None (default), the pivot point is the coordinate system origin (0.0, 0.0). **Returns** - Affine ### `scale(*scaling: float) -> Affine` Create a scaling transform from a scalar or vector. **Parameters** - `*scaling` (float) - One or two scaling factors. A scalar value will scale in both dimensions equally. A vector scaling value scales the dimensions independently. **Returns** - Affine ### `shear(x_angle: float = 0.0, y_angle: float = 0.0) -> Affine` Create a shear transform along one or both axes. **Parameters** - `x_angle` (float) - Shear angle in degrees parallel to the x-axis. - `y_angle` (float) - Shear angle in degrees parallel to the y-axis. **Returns** - Affine ### `translation(xoff: float, yoff: float) -> Affine` Create a translation transform from an offset vector. **Parameters** - `xoff` (float) - Translation offset in x direction. - `yoff` (float) - Translation offset in y direction. **Returns** - Affine ``` -------------------------------- ### Apply Rotation Transforms in Python Source: https://context7.com/rasterio/affine/llms.txt Demonstrates how to create and apply rotation transformations in Python using the Affine library. It covers counter-clockwise rotation around the origin and around a specified pivot point. ```python from affine import Affine # Rotate 45 degrees counter-clockwise around origin rot45 = Affine.rotation(45.0) point = (1, 0) rotated = rot45 * point print(f"({rotated[0]:.4f}, {rotated[1]:.4f})") # (0.7071, 0.7071) # Rotate 90 degrees (exact values for multiples of 90) rot90 = Affine.rotation(90) print(rot90 * (1, 0)) # (0.0, 1.0) print(rot90 * (0, 1)) # (-1.0, 0.0) # Rotate around a custom pivot point pivot = (5, 5) rot_pivot = Affine.rotation(90, pivot=pivot) print(rot_pivot * (6, 5)) # (5.0, 6.0) print(rot_pivot * (5, 5)) # (5.0, 5.0) - pivot unchanged ``` -------------------------------- ### Combine Affine Transformations in Python Source: https://github.com/rasterio/affine/blob/main/README.rst Illustrates how to combine multiple affine transformations by multiplying their respective matrices. The order of multiplication matters for the final transformation. ```python from affine import Affine # Define a translation matrix trans_matrix = Affine.translation(1.0, 5.0) # Define a rotation matrix rot_matrix = Affine.rotation(45.0) # Combine transformations: translation followed by rotation combined_matrix = trans_matrix * rot_matrix print(combined_matrix) ``` -------------------------------- ### Apply Translation Transforms in Python Source: https://context7.com/rasterio/affine/llms.txt Shows how to create and apply translation transformations using the Affine library in Python. It includes translating points and combining multiple translation operations. ```python from affine import Affine # Translate by (2, -5) - move right 2 units, down 5 units trans = Affine.translation(2, -5) print(tuple(trans)) # (1.0, 0.0, 2.0, 0.0, 1.0, -5.0, 0.0, 0.0, 1.0) # Apply translation to a point point = (10, 20) new_point = trans * point print(new_point) # (12.0, 15.0) # Chain multiple translations combined = Affine.translation(3, 5) * Affine.translation(-2, 3.5) print(combined.xoff, combined.yoff) # 1.0 8.5 ``` -------------------------------- ### Load and Save World Files (.tfw, .jgw) Source: https://context7.com/rasterio/affine/llms.txt Demonstrates how to load and save world files using `affine.loadsw` and `affine.dumpsw`. These functions facilitate the georeferencing of images by converting between Affine transforms and the standard world file format. ```python import affine # World file content (one value per line): # a (x-scale), d (y-rotation), b (x-rotation), e (y-scale), c (x-origin), f (y-origin) world_file_content = """ 1.0 0.0 0.0 -1.0 100.5 199.5 """ # Load world file string into Affine # Note: loadsw converts from center-based to corner-based coordinates transform = affine.loadsw(world_file_content) print(transform) # Save Affine to world file string # Note: dumpsw converts from corner-based to center-based coordinates output = affine.dumpsw(transform) print(output) ``` -------------------------------- ### Apply Shear Transforms in Python Source: https://context7.com/rasterio/affine/llms.txt Explains how to create and apply shear transformations along the x and/or y axes using the Affine library in Python. It shows shearing by specified angles. ```python from affine import Affine # Shear along x-axis by 30 degrees shear_x = Affine.shear(30) point = (0, 10) print(f"({shear_x * point[0]:.4f}, {shear_x * point[1]:.4f})") # Shear along both axes shear_xy = Affine.shear(x_angle=45, y_angle=30) print(shear_xy * (1, 1)) # Shear along y-axis only shear_y = Affine.shear(y_angle=45) print(shear_y * (10, 0)) # (10.0, 10.0) ``` -------------------------------- ### Compose Affine Transforms in Python Source: https://context7.com/rasterio/affine/llms.txt Demonstrates how to combine multiple Affine transformations in Python using multiplication operators (`*` or `@`). It highlights that the order of operations matters (right-to-left application). ```python from affine import Affine # Combine rotation and translation # First rotate, then translate trans = Affine.translation(1.0, 5.0) rot = Affine.rotation(45.0) combined = trans * rot # Rotate first, then translate point = (1, 0) print(combined * point) # Rotated 45 deg, then moved by (1, 5) # Using @ operator (preferred for matrix multiplication) rot_scale = Affine.rotation(30) @ Affine.scale(2, 3) print(rot_scale * (1, 0)) # Complex transformation chain transform = ( Affine.translation(10, 10) @ Affine.rotation(45) @ Affine.scale(2) @ Affine.translation(-5, -5) # Move origin to (5,5), scale, rotate, move back ) ``` -------------------------------- ### Approximate Equality Comparison for Affine Transforms Source: https://context7.com/rasterio/affine/llms.txt Explains how to compare Affine transforms for approximate equality, which is essential when dealing with floating-point inaccuracies. It covers using the default precision and specifying a custom precision level for the comparison. ```python from affine import Affine import affine # Default precision comparison t1 = Affine(1.0, 0.00001, 0, -0.00001, 1.0, 0.00001) t2 = Affine.identity() print(t1.almost_equals(t2)) # True (within default EPSILON) # Custom precision t3 = Affine(1.0, 0.0001, 0, 0, 1.0, 0) print(t3.almost_equals(Affine.identity())) # False (default EPSILON=1e-5) print(t3.almost_equals(Affine.identity(), precision=1e-3)) # True # Set global epsilon for is_identity and other checks affine.set_epsilon(1e-10) # More strict comparisons ``` -------------------------------- ### NumPy Integration for Affine Transforms Source: https://context7.com/rasterio/affine/llms.txt Shows how to convert Affine objects to NumPy arrays for efficient batch coordinate transformations. This includes converting to a 3x3 matrix, specifying data types, and transforming entire coordinate grids using NumPy's broadcasting capabilities. ```python from affine import Affine import numpy as np # Convert Affine to 3x3 NumPy array t = Affine(2, 0, 3, 0, 3, 2) arr = np.array(t) print(arr.shape) # (3, 3) print(arr) # [[2. 0. 3.] # [0. 3. 2.] # [0. 0. 1.]] # Specify dtype arr32 = np.array(t, dtype=np.float32) print(arr32.dtype) # float32 # Transform coordinate grids (e.g., for raster processing) transform = Affine(2, 0, 3, 0, 3, 2) @ Affine.rotation(45) shape = (4, 5) vx, vy = np.meshgrid(np.arange(shape[1]), np.arange(shape[0])) # Apply transform to entire grid at once px, py = transform @ (vx, vy) print(f"Input shape: {vx.shape}, Output shape: {px.shape}") # Also works with 3-element tuples (x, y, 1) px, py, pw = transform @ (vx, vy, np.ones(shape)) ``` -------------------------------- ### Perform In-Place Transformation on Points Source: https://context7.com/rasterio/affine/llms.txt Illustrates the use of the `itransform` method for efficiently transforming a mutable sequence of points in-place. This is particularly useful for large datasets where memory efficiency is crucial. ```python from affine import Affine # Transform multiple points in-place points = [(4, 1), (-1, 0), (3, 2)] transform = Affine.scale(-2) result = transform.itransform(points) print(result) # None (modifies in-place) print(points) # [(-8, -2), (2, 0), (-6, -4)] ``` -------------------------------- ### Convert Affine to Shapely Affinity Parameters Source: https://context7.com/rasterio/affine/llms.txt Shows how to convert an Affine transformation into the parameter format required by Shapely's affinity module. The output is a tuple suitable for functions like `shapely.affinity.affine_transform`. ```python from affine import Affine # Create a transform t = Affine(425.0, 0.0, -237481.5, 0.0, -425.0, 237536.4) # Get Shapely-compatible parameters (a, b, d, e, xoff, yoff) shapely_params = t.to_shapely() print(shapely_params) # (425.0, 0.0, 0.0, -425.0, -237481.5, 237536.4) # Use with Shapely (example) # from shapely import affinity # from shapely.geometry import Point # transformed_geom = affinity.affine_transform(Point(0, 0), shapely_params) ``` -------------------------------- ### Accessing Affine Transform Column Vectors Source: https://context7.com/rasterio/affine/llms.txt Demonstrates how to access the components of an Affine transformation matrix as column vectors. This is useful for certain geometric calculations where individual vector components are needed, such as the x-axis vector, y-axis vector, and translation vector. ```python from affine import Affine t = Affine(2, 3, 4, 5, 6, 7) # Get column vectors: (a,d), (b,e), (c,f) col1, col2, col3 = t.column_vectors print(f"X-axis vector: {col1}") # (2, 5) print(f"Y-axis vector: {col2}") # (3, 6) print(f"Translation: {col3}") # (4, 7) ``` -------------------------------- ### Permutation Transform for Swapping Coordinates Source: https://context7.com/rasterio/affine/llms.txt Illustrates the creation and use of a permutation matrix that swaps the x and y coordinates. Applying the permutation transform to a point results in its coordinates being exchanged. Applying it twice returns the original coordinates, confirming it's an involution. ```python from affine import Affine # Permutation swaps x and y perm = Affine.permutation() print(perm * (3, 7)) # (7.0, 3.0) # Applying permutation twice returns to original double_perm = perm @ perm print(double_perm.is_identity) # True ``` -------------------------------- ### Inspect Affine Transform Properties Source: https://context7.com/rasterio/affine/llms.txt Explains how to inspect various geometric properties of an Affine transformation, including identity check, determinant (area scaling factor), degeneracy, and rectilinear, conformal, and orthonormal characteristics. It also shows how to retrieve rotation angle and eccentricity. ```python from affine import Affine # Identity check t = Affine.identity() print(t.is_identity) # True # Determinant (area scaling factor) scale = Affine.scale(2, 3) print(scale.determinant) # 6.0 (area multiplied by 6) # Degenerate check (cannot be inverted, collapses to line/point) deg = Affine.scale(0) print(deg.is_degenerate) # True # Rectilinear (preserves axis alignment) print(Affine.rotation(90).is_rectilinear) # True print(Affine.rotation(45).is_rectilinear) # False # Conformal (preserves angles, no shear) print(Affine.rotation(30).is_conformal) # True print(Affine.shear(10).is_conformal) # False # Orthonormal (rigid motion, no scaling/shear) print(Affine.rotation(45).is_orthonormal) # True print(Affine.scale(2).is_orthonormal) # False # Rotation angle and eccentricity t = Affine.rotation(30) @ Affine.scale(2, 3) print(f"Rotation: {t.rotation_angle:.1f} degrees") print(f"Eccentricity: {t.eccentricity:.4f}") ``` -------------------------------- ### Affine Properties Source: https://github.com/rasterio/affine/blob/main/docs/src/index.md Properties to inspect the characteristics of an Affine transformation. ```APIDOC ## Affine Properties ### `column_vectors` The values of the transform as three 2D column vectors. **Returns** - tuple[tuple[float, float], tuple[float, float], tuple[float, float]] - Ordered (a, d), (b, e), (c, f). ### `eccentricity` The eccentricity of the affine transformation. This value represents the eccentricity of an ellipse under this affine transformation. **Raises** - NotImplementedError - For improper transformations. ### `is_conformal` True if the transform is conformal. i.e., if angles between points are preserved after applying the transform, within rounding limits. This implies that the transform has no effective shear. **Returns** - bool ### `is_identity` True if this transform equals the identity matrix, within rounding limits. **Returns** - bool ### `is_orthonormal` True if the transform is orthonormal. Which means that the transform represents a rigid motion, which has no effective scaling or shear. Mathematically, this means that the axis vectors of the transform matrix are perpendicular and unit-length. Applying an orthonormal transform to a shape always results in a congruent shape. **Returns** - bool ### `is_rectilinear` True if the transform is rectilinear. i.e., whether a shape would remain axis-aligned, within rounding limits, after applying the transform. **Returns** - bool ### `rotation_angle` The rotation angle in degrees of the affine transformation. This is the rotation angle in degrees of the affine transformation, assuming it is in the form M = R S, where R is a rotation and S is a scaling. **Raises** - UndefinedRotationError - For improper and degenerate transformations. **Returns** - float ### `xoff` Alias for ‘c’. **Returns** - float ### `yoff` Alias for ‘f’. **Returns** - float ``` -------------------------------- ### Mutable Sequence Transformation with Affine Source: https://context7.com/rasterio/affine/llms.txt Demonstrates how Affine transforms can modify mutable sequences like Python lists in-place. The `itransform` method applies the affine transformation to each coordinate pair within the sequence. ```python import array from affine import Affine coords = [[1.0, 2.0], [3.0, 4.0], [5.0, 6.0]] # Example transformation: translation by (10, 20) transformed_coords = Affine.translation(10, 20).itransform(coords) print(coords) # [[11.0, 22.0], [13.0, 24.0], [15.0, 26.0]] ``` -------------------------------- ### Calculate Inverse Affine Transformation in Python Source: https://github.com/rasterio/affine/blob/main/README.rst Demonstrates how to compute the inverse of an affine transformation matrix using the bitwise NOT operator (~). This is useful for converting world coordinates back to image coordinates. ```python from affine import Affine # Example GDAL geotransform geotransform = (-237481.5, 425.0, 0.0, 237536.4, 0.0, -425.0) # Convert to Affine matrix fwd = Affine.from_gdal(*geotransform) # Calculate the inverse transformation rev = ~fwd # Example usage: apply inverse to a transformed point to get original coordinates col, row = 0, 100 original_coords = rev * (fwd * (col, row)) print(original_coords) ``` -------------------------------- ### Convert Between Affine and GDAL GeoTransform Source: https://context7.com/rasterio/affine/llms.txt Details the process of converting between Affine transformations and the GDAL GeoTransform format. It covers creating an Affine transform from a GDAL tuple, converting pixel coordinates to world coordinates, and converting back to the GDAL format. ```python from affine import Affine # GDAL GeoTransform format: (c, a, b, f, d, e) # c: x-coordinate of upper-left corner # a: pixel width (x-resolution) # b: row rotation (typically 0) # f: y-coordinate of upper-left corner # d: column rotation (typically 0) # e: pixel height (negative for north-up images) geotransform = (-237481.5, 425.0, 0.0, 237536.4, 0.0, -425.0) # Create Affine from GDAL GeoTransform fwd = Affine.from_gdal(*geotransform) print(f"X offset: {fwd.xoff}, Y offset: {fwd.yoff}") print(f"Pixel size: {fwd.a} x {fwd.e}") # Convert pixel coordinates to world coordinates col, row = 0, 100 world_x, world_y = fwd * (col, row) print(f"Pixel (0, 100) -> World ({world_x}, {world_y})") # Output: Pixel (0, 100) -> World (-237481.5, 195036.4) # Reverse: world coordinates to pixel coordinates rev = ~fwd pixel = rev * (world_x, world_y) print(f"World -> Pixel: ({pixel[0]:.1f}, {pixel[1]:.1f})") # Convert back to GDAL format gdal_tuple = fwd.to_gdal() print(gdal_tuple) # (-237481.5, 425.0, 0.0, 237536.4, 0.0, -425.0) ``` -------------------------------- ### Convert GDAL Geotransform to Affine Matrix in Python Source: https://github.com/rasterio/affine/blob/main/README.rst Explains how to convert a GDAL geotransform (a sequence of 6 numbers) into an Affine matrix using the `from_gdal` class method. This is useful for mapping image coordinates to world coordinates in GIS. ```python from affine import Affine # Example GDAL geotransform geotransform = (-237481.5, 425.0, 0.0, 237536.4, 0.0, -425.0) # Convert to Affine matrix fwd = Affine.from_gdal(*geotransform) print(fwd) # Example usage: find world coordinates for a pixel (col=0, row=100) col, row = 0, 100 print(fwd * (col, row)) ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.