Spherical Transformer: Adapting Spherical Signal to CNNs

Haikuan Du, Hui Cao, Shen Cai, Junchi Yan, Siyu ZhangarXiv 2021

TL;DR

This paper introduces the "Spherical Transformer" (STM), a novel module that transforms spherical signals into structured vectors, enabling the direct application of standard 2D Convolutional Neural Networks (CNNs) to spherical data. This approach allows for the reuse of well-established CNN architectures and pre-trained models for tasks like 3D object classification and semantic segmentation on spherical data, achieving state-of-the-art results.

What Problem Does This Paper Address?

The proliferation of omnidirectional sensors (like 360° cameras) and the increasing importance of 3D data have created a demand for computer vision models that can effectively process signals in the spherical domain. However, standard 2D CNNs, which excel at processing structured grid-like data (e.g., images), are not inherently suited for the unstructured nature of spherical data. Applying them directly often requires distorting projections (like equirectangular maps), which can lead to significant information loss, especially near the poles. Existing methods that attempt to adapt CNNs to spherical data often rely on specialized, inflexible sampling techniques or custom architectures, limiting their reusability and the ability to leverage the vast ecosystem of pre-trained 2D CNN models. This paper aims to bridge this gap by providing a general mechanism to adapt spherical signals for standard CNN processing.

Methods

The core contribution is the Spherical Transformer Module (STM). The STM addresses the unstructured nature of spherical data in two main steps:

  1. Spherical Sampling and Transformer Grid Construction: The method utilizes a structured spherical sampling method, specifically HEALPix (Hierarchical Equal Area isoLatitude Pixelization), which provides a relatively uniform distribution of points on the sphere. For each spherical point, the STM constructs a "transformer grid" by considering the point's own feature and the features of its adjacent points. This local neighborhood information is crucial for capturing spatial relationships. For points with fewer than the standard number of neighbors, missing values are handled by setting them to -1 or 0.
  2. Vector Transformation: The features from the constructed transformer grid are then transformed into structured vectors. This process is inspired by Spatial Transformer Networks (STNs) and effectively "unrolls" the local spherical neighborhood into a format that a standard 3x3 convolution can process. The paper details a specific implementation where a 3x3 convolution with a stride of 1x3 is used to process these transformed vectors.

The paper also introduces a rendering-based projection method for 3D object classification. This method aims to capture local shading information from different viewpoints of a 3D object and project it onto a spherical image, enriching the feature representation. Additionally, they propose a rotational-equivariant model by incorporating 1x1 convolution kernels alongside standard convolutions, enhancing the model's robustness to rotations.

Datasets

The proposed method is evaluated on three main tasks:

  • Spherical MNIST: A dataset of handwritten digits projected onto a sphere.
  • ModelNet40: A widely used benchmark for 3D object classification, containing shapes across 40 categories. The paper uses both depth-based and rendering-based projections of ModelNet40.
  • Stanford 2D3DS: A dataset for semantic segmentation of indoor scenes, providing RGB-D images and semantic annotations. The paper uses equirectangular RGB images from this dataset.

Key Insights and Ideas

  • Bridging the Gap: The most significant insight is the development of a general module (STM) that allows standard CNNs to process spherical data without requiring entirely new architectures. This unlocks the potential of transfer learning and pre-trained models for spherical vision tasks.
  • Structured Local Neighborhoods: The HEALPix grid, combined with the transformer grid construction, effectively imposes a local structure on the otherwise unstructured sphere, making it amenable to convolutional operations.
  • Rendering for Richer 3D Features: The rendering-based projection method demonstrates that combining geometric information (depth) with appearance cues (shading) can significantly improve 3D object classification, especially when dealing with rotational variations.
  • Rotational Equivariance as a Feature: Explicitly incorporating rotational equivariance through 1x1 convolutions is shown to be effective for improving 3D object classification performance, particularly when tested with arbitrary rotations.

Key Results

  • Spherical MNIST: The proposed STM-based CNN achieves a classification accuracy of 99.36%, outperforming existing methods like S2CNN (96.00%) and UGSCNN (99.23%), while using significantly fewer parameters (32k vs. 58k/62k).
  • 3D Object Classification (ModelNet40):
    • The depth-based projection method achieves 92.3% accuracy with VGG-11, and the rotational-equivariant version reaches 92.7% accuracy.
  • The rendering-based approach, when combined with pre-training, achieves 91.1% accuracy.
  • The overall method, combining depth and rendering features, achieves the highest accuracy of 93.0%.
  • The rotational-equivariant model shows superior performance on SO(3)/SO(3) classification (91.3% vs. 87.7% for depth-based VGG11).
  • Spherical Image Semantic Segmentation (2D3DS): The proposed spherical segmentation model significantly outperforms UGSCNN and two planar-based methods (U-Net, FCN8s) in terms of mIoU score across various parameter regimes, notably capturing finer details like beam structures.

Limitations and Future Work

  • Sampling Method Dependence: While HEALPix is effective, the paper acknowledges that other sampling methods (like icosahedral grids) might require different transformer grid configurations (e.g., 1x7 kernels instead of 3x3). The choice of sampling method can influence performance.
  • Projection Artifacts: The paper notes that planar projections inherently lead to information loss. While their rendering-based method mitigates some issues, it's still a projection.
  • Future Work: The authors suggest that the increasing availability of spherical sensors will drive further demand for specialized models. Their work lays a foundation for adapting existing powerful CNN architectures to this domain, implying that further exploration of different CNN backbones and spherical data representations is a natural next step. The success in both classification and segmentation suggests broad applicability.

Summary updated

Abstract

Convolutional neural networks (CNNs) have been widely used in various vision tasks, e.g. image classification, semantic segmentation, etc. Unfortunately, standard 2D CNNs are not well suited for spherical signals such as panorama images or spherical projections, as the sphere is an unstructured grid. In this paper, we present Spherical Transformer which can transform spherical signals into vectors that can be directly processed by standard CNNs such that many well-designed CNNs architectures can be reused across tasks and datasets by pretraining. To this end, the proposed method first uses local structured sampling methods such as HEALPix to construct a transformer grid by using the information of spherical points and its adjacent points, and then transforms the spherical signals to the vectors through the grid. By building the Spherical Transformer module, we can use multiple CNN architectures directly. We evaluate our approach on the tasks of spherical MNIST recognition, 3D object classification and omnidirectional image semantic segmentation. For 3D object classification, we further propose a rendering-based projection method to improve the performance and a rotational-equivariant model to improve the anti-rotation ability. Experimental results on three tasks show that our approach achieves superior performance over state-of-the-art methods.
BibTeX
@misc{du2021spherical,
  author = {Haikuan Du and Hui Cao and Shen Cai and Junchi Yan and Siyu Zhang},
  title = {{Spherical Transformer: Adapting Spherical Signal to CNNs}},
  year = {2021},
  eprint = {2101.03848},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2101.03848},
}
Figure