Compose a sphere-native model

Surface

Stability

Canonical import

Contract

Public components or entries

spherical-internimage-portability

Experimental

panorai.experimental.deep_learning

panorai-spherical-internimage/v1

DenseInternImageOutput, InternImageGAssets, InternImageGDenseClassifier, InternImageShardSpec, InternImageTermsNotAcceptedError, LoadedInternImageG, SphericalDCNv3, SphericalDCNv3Record, SphericalInternImagePortReport, acquire_internimage_g, attention_pool_class_contributions, load_pretrained_internimage_g, port_internimage_to_spherical, spherical_dcnv3_core, panorai.experimental.deep_learning.internimage.SPHERICAL_INTERNIMAGE_INTERFACE, panorai.experimental.deep_learning.internimage.INTERNIMAGE_G_REPOSITORY, panorai.experimental.deep_learning.internimage.INTERNIMAGE_G_REVISION, panorai.experimental.deep_learning.internimage.INTERNIMAGE_G_SHARDS, panorai.experimental.deep_learning.internimage.DenseInternImageOutput, panorai.experimental.deep_learning.internimage.InternImageGAssets, panorai.experimental.deep_learning.internimage.InternImageGDenseClassifier, panorai.experimental.deep_learning.internimage.InternImageShardSpec, panorai.experimental.deep_learning.internimage.InternImageTermsNotAcceptedError, panorai.experimental.deep_learning.internimage.LoadedInternImageG, panorai.experimental.deep_learning.internimage.SphericalDCNv3, panorai.experimental.deep_learning.internimage.SphericalDCNv3Record, panorai.experimental.deep_learning.internimage.SphericalInternImagePortReport, panorai.experimental.deep_learning.internimage.acquire_internimage_g, panorai.experimental.deep_learning.internimage.attention_pool_class_contributions, panorai.experimental.deep_learning.internimage.load_pretrained_internimage_g, panorai.experimental.deep_learning.internimage.port_internimage_to_spherical, panorai.experimental.deep_learning.internimage.spherical_dcnv3_core

deep-learning-support

Experimental

panorai.experimental.deep_learning

panorai-deep-learning-support/v1-experimental

DA3Assets, DA3METRIC_LARGE, DA3TermsNotAcceptedError, DA3_CANONICAL_FOCAL_PX, DA3_CHECKPOINT_REVISION, DA3_MODEL_ID, DA3_PATCH_SIZE, DA3_SOURCE, DA3_SOURCE_COMMIT, DenseFCNOutput, DenseSemanticEvidence, ExternalArtifactRecord, ExternalArtifactSpec, IMAGENET_PROXY_VOCABULARY, INTERNIMAGE_G_REPOSITORY, INTERNIMAGE_G_REVISION, INTERNIMAGE_G_SHARDS, ImageNetFCN, ImageNetWeightRecord, LoadedDA3MetricModel, LoadedImageNetModel, LoadedSphericalDepthModel, METRIC3D_CHECKPOINT_REVISION, METRIC3D_CONVNEXT_LARGE_V1, METRIC3D_CONVNEXT_TINY_V1, METRIC3D_SOURCE, METRIC3D_SOURCE_COMMIT, Metric3DAssets, PortedLayer, SPHERICAL_DA3_METRIC_DEPTH_INTERFACE, SPHERICAL_INTERNIMAGE_INTERFACE, SPHERICAL_METRIC_DEPTH_INTERFACE, SPHERICAL_PROXY_SEGMENTATION_INTERFACE, SPHERICAL_SEMANTIC_SEGMENTATION_INTERFACE, SPHERICAL_TORCH_CONVOLUTION_INTERFACE, SUPPORTED_IMAGENET_MODELS, Sam21Assets, Sam21HieraLargeSegmenter, Sam21TermsNotAcceptedError, SemanticProxyConcept, SphericalBinaryMask, SphericalConv2d, SphericalConvTranspose2d, SphericalResizeConv2d, SphericalMaskProposal, SphericalMaskProposalSet, SphericalMaxPool2d, SphericalPortReport, SphericalProxySegmenter, SphericalSeed, SphericalSegment, SphericalSegmentationConfig, SphericalSegmentationResult, SphericalSemanticSegmenter, UpstreamTermsNotAcceptedError, acquire_metric3d_convnext_large_v1, acquire_sam21_hiera_large, class_activation_map, concept_evidence_from_imagenet, fibonacci_coverage_seeds, load_pretrained_imagenet_model, load_sam21_hiera_large, load_spherical_metric3d_convnext_large_v1, merge_proposals, port_module, port_module_with_report, prefetch_imagenet_weights, resolve_panoptic_map, select_semantic_seeds, spherical_area_average, sphericalize, mask_rcnn, panorai.experimental.deep_learning.pretrained.SUPPORTED_IMAGENET_MODELS, panorai.experimental.deep_learning.pretrained.ImageNetWeightRecord, panorai.experimental.deep_learning.pretrained.LoadedImageNetModel, panorai.experimental.deep_learning.pretrained.load_pretrained_imagenet_model, panorai.experimental.deep_learning.pretrained.prefetch_imagenet_weights

spherical-core-torch

Stable

panorai.core.torch

panorai-core-operations/v1

SPHERICAL_TORCH_CONVOLUTION_INTERFACE, PortedLayer, Sequential, SphericalAreaMean, SphericalAreaSum, SphericalAvgPool2d, SphericalConv2d, SphericalConvTranspose2d, SphericalResizeConv2d, SphericalFilter2d, SphericalGaussianBlur2d, SphericalGradient, SphericalLaplacian, SphericalMaxPool2d, SphericalNeighborhoodMax, SphericalNeighborhoodMin, SphericalPortReport, SphericalResize, SphericalScaleExtrema, port_module, port_module_with_report, spherical_area_average, panorai.core.torch.porting.PortedLayer, panorai.core.torch.porting.SphericalPortReport, panorai.core.torch.porting.port_module, panorai.core.torch.porting.port_module_with_report, panorai.image_processing.torch.SPHERICAL_TORCH_CONVOLUTION_INTERFACE, panorai.image_processing.torch.PortedLayer, panorai.image_processing.torch.Sequential, panorai.image_processing.torch.SphericalAreaMean, panorai.image_processing.torch.SphericalAreaSum, panorai.image_processing.torch.SphericalAvgPool2d, panorai.image_processing.torch.SphericalConv2d, panorai.image_processing.torch.SphericalConvTranspose2d, panorai.image_processing.torch.SphericalResizeConv2d, panorai.image_processing.torch.SphericalFilter2d, panorai.image_processing.torch.SphericalGaussianBlur2d, panorai.image_processing.torch.SphericalGradient, panorai.image_processing.torch.SphericalLaplacian, panorai.image_processing.torch.SphericalMaxPool2d, panorai.image_processing.torch.SphericalNeighborhoodMax, panorai.image_processing.torch.SphericalNeighborhoodMin, panorai.image_processing.torch.SphericalPortReport, panorai.image_processing.torch.SphericalResize, panorai.image_processing.torch.SphericalScaleExtrema, panorai.image_processing.torch.port_module, panorai.image_processing.torch.port_module_with_report, panorai.image_processing.torch.spherical_area_average

spherical-model-workflow-torch

Experimental

panorai.workflow.torch

panorai-spherical-model-workflow/v1

SphericalImageModule

spherical-ops-torch

Stable

panorai.ops.spherical.nn

panorai-spherical-ops-torch/v1

AdaptiveAvgPool2d, AvgPool2d, Closing, Conv2d, ConvTranspose2d, Dilate, Erode, GlobalAveragePool, Interpolate, MaxPool2d, Opening, PlanarSpatialOperationError, Resize, Rotate, SphericalConv2d, SphericalConvTranspose2d, SphericalMaxPool2d, SphericalValidationReport, ValidatedLayer, from_planar, execute_with_masks, spherical_area_average, transform_grid, transform_mask, validate

Tutorial contract

Application

Custom filtering, scale space, CNN, CAM, depth, or segmentation model

Input

Floating CHW/NCHW ERP tensor, or EquirectangularImage

Output

Tensor tree or typed ERP field tree

Strategy

Sphere-native composition

API

panorai.core.numpy / panorai.core.torch and panorai.workflow

Stability

Experimental

Dependencies

NumPy required; Torch optional

Evidence type

Analytic geometry, backend parity, autograd, and integration regression

The composition rule is intentionally the same as the selected numerical backend: construct small spherical operations, write normal control flow, and call the model. apply_spherical is not required for a composed model.

How this application is composed

This tutorial operates at the core layer itself: immutable operation specs, one explicit numerical backend, ordinary backend control flow, and an optional typed-container bridge. It intentionally does not introduce a DoG, CNN or segmentation wrapper. Those can be built from the same vocabulary; established PanorAi application wrappers add defaults and diagnostics only where those are part of the method.

from panorai.core.numpy import Module, SphericalGaussianBlur2d

class DifferenceOfGaussians(Module):
    def __init__(self, sigma_a=1.0, sigma_b=2.0):
        self.a = SphericalGaussianBlur2d(sigma_a)
        self.b = SphericalGaussianBlur2d(sigma_b)

    def forward(self, image):
        return self.b(image) - self.a(image)

dog = DifferenceOfGaussians()
response_nchw = dog(image_nchw)

To accept a typed ERP container as well, inherit the backend-specific SphericalImageModule and declare the input and output field semantics:

from panorai.workflow import SphericalInputSpec, SphericalOutputSpec
from panorai.workflow.numpy import SphericalImageModule

class ContainerDoG(SphericalImageModule):
    def __init__(self):
        super().__init__(
            input_spec=SphericalInputSpec(
                field="image", grayscale=True, scale=1 / 255
            ),
            output_specs={"dog": SphericalOutputSpec.continuous()},
        )
        self.dog = DifferenceOfGaussians()

    def forward(self, image):
        return {"dog": self.dog(image)}

fields = ContainerDoG().predict(panorama)
response_hw = fields["dog"].field("dog")

The default policy accepts only fully supported, valid inputs. A method that supports partial observations must opt into the explicit policy and return RasterFieldResult masks; numeric zero is never interpreted as invalid.

See Composable spherical operations for the complete primitive vocabulary, Torch parameter sharing, native-backend boundary, multiresolution outputs, and application composition patterns.