Skip to content
This repository has been archived by the owner on Feb 7, 2023. It is now read-only.

question: does caffe2 support 3D images? #587

Closed
emoebel opened this issue May 16, 2017 · 3 comments
Closed

question: does caffe2 support 3D images? #587

emoebel opened this issue May 16, 2017 · 3 comments
Labels

Comments

@emoebel
Copy link

emoebel commented May 16, 2017

Hello,
I have a simple question: does caffe2 support 3D images? I'm not speaking about channel dimension, I'm speaking about 3 spatial dimensions, like in medical tomography for example. This requires 3D conv layers and 3D pooling layers. I know that elektronn and keras support 3D images, but last I checked caffe did not. Now that caffe2 is out, I was wondering if this is the case now?
Best,
Lazyleaf

@pietern
Copy link
Contributor

pietern commented May 17, 2017

@asaadaldien worked on N-D convolutions so can best answer this.

@asaadaldien
Copy link
Contributor

asaadaldien commented May 22, 2017

Yes we do have an implementation for 3D (convolution, max pooling, average pooling and spatial batch normalization).
For convolution you can use model.ConvND and pass 3d kernel, strides and padding parameters here is an example :
model.ConvND("x", "y", kernels=[3,3,3], strides=[1,1,1], pads=[1,1,1]*2)
model.MaxPool("y", "pooled_y", kernels=[2,2,2], strides=[1,1,1], pads=[1,1,1]*2)

@williford
Copy link
Contributor

williford commented May 22, 2017

Actually, caffe 1 has supported ND convolutions since:
BVLC/caffe#2049

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

4 participants