[Paper Review] Chunkflow: Distributed Hybrid Cloud Processing of Large 3D Images by Convolutional Nets
Chunkflow is a hybrid-cloud framework that enables distributed, cost-efficient inference of 3D ConvNets on tera- and petavoxel biomedical images by splitting volumes into overlapping chunks, processing them across local and cloud GPUs/CPU clusters, and blending results. It leverages fault-tolerant task queuing (AWS SQS), supports PyTorch and PZnet backends, and enables real-time visualization and large-scale evaluation, reducing costs via unstable cloud instances like spot or preemptible VMs.
It is now common to process volumetric biomedical images using 3D Convolutional Networks (ConvNets). This can be challenging for the teravoxel and even petavoxel images that are being acquired today by light or electron microscopy. Here we introduce chunkflow, a software framework for distributing ConvNet processing over local and cloud GPUs and CPUs. The image volume is divided into overlapping chunks, each chunk is processed by a ConvNet, and the results are blended together to yield the output image. The frontend submits ConvNet tasks to a cloud queue. The tasks are executed by local and cloud GPUs and CPUs. Thanks to the fault-tolerant architecture of Chunkflow, cost can be greatly reduced by utilizing cheap unstable cloud instances. Chunkflow currently supports PyTorch for GPUs and PZnet for CPUs. To illustrate its usage, a large 3D brain image from serial section electron microscopy was processed by a 3D ConvNet with a U-Net style architecture. Chunkflow provides some chunk operations for general use, and the operations can be composed flexibly in a command line interface.
Motivation & Objective
- To address the computational and memory bottlenecks of processing tera- and petavoxel-scale 3D biomedical images with 3D ConvNets.
- To reduce the cost and infrastructure burden of running large-scale 3D ConvNet inference by leveraging underutilized, low-cost cloud instances such as AWS spot or Google preemptible VMs.
- To enable flexible, vendor-agnostic deployment of distributed inference across local and public cloud resources without vendor or cluster binding.
- To support real-time visualization and large-scale evaluation of inference results during processing to improve model debugging and generalization.
- To provide a composable, command-line interface for flexible composition of chunk operations in 3D image processing pipelines.
Proposed method
- The framework divides large 3D image volumes into overlapping, manageable chunks to enable distributed processing.
- It uses a producer-consumer architecture with AWS Simple Queue Service (SQS) to decouple task submission from execution, enabling dynamic scaling of workers.
- Workers—running on local machines or cloud instances—fetch tasks from the SQS queue, process their assigned image chunks using PyTorch (GPU) or PZnet (CPU), and return results.
- Results from individual chunks are blended using overlapping regions to produce a globally consistent output image.
- The system supports fault tolerance by reprocessing failed tasks, enabling reliable use of unstable, low-cost cloud instances such as spot or preemptible VMs.
- It integrates with neuroglancer precomputed format to allow real-time visualization of inference results, including thumbnails and affinity maps, during processing.
Experimental results
Research questions
- RQ1Can a hybrid-cloud, distributed framework efficiently and cost-effectively perform 3D ConvNet inference on tera- and petavoxel-scale biomedical images?
- RQ2How can fault-tolerant task queuing and dynamic worker scaling reduce computational costs when using unreliable, low-cost cloud instances?
- RQ3To what extent can CPU-based inference with PZnet match or exceed GPU-based inference in throughput per dollar for large 3D image datasets?
- RQ4How can real-time visualization of intermediate results improve debugging and large-scale evaluation of 3D ConvNet inference pipelines?
- RQ5Can a composable command-line interface enable flexible, modular processing of 3D image chunks across diverse computational backends?
Key findings
- Chunkflow successfully processed a large 3D brain image from serial section electron microscopy using a U-Net-style 3D ConvNet, demonstrating scalability on petascale data.
- The use of fault-tolerant task queuing enabled reliable execution on unstable cloud instances, significantly reducing computational costs.
- CPU inference with PZnet achieved higher throughput per dollar than GPU inference in some cases, making CPU-based processing more cost-effective for certain models.
- Real-time visualization of downsampled thumbnails and affinity maps allowed users to monitor and validate results during processing, enabling early detection of errors.
- The composable command-line interface allowed flexible composition of chunk operations, enhancing reusability and extensibility across different processing pipelines.
- The framework achieved global consistency in output despite chunk-level processing by blending overlapping regions, with minimal visual artifacts even when cropping size was less than half the patch size.
Read this paper
Open the full text in the Nubint reader and ask about any passage as you read.
Read this paper on NubintThis review was generated by AI from the original paper. Please check the paper before citing it.