Skip to content

Instantly share code, notes, and snippets.

@John1231983
Last active February 15, 2017 11:58
Show Gist options
  • Save John1231983/f54fce530a6728d62a0c6937faecdcee to your computer and use it in GitHub Desktop.
Save John1231983/f54fce530a6728d62a0c6937faecdcee to your computer and use it in GitHub Desktop.
# Simple single-layer network to showcase editing model parameters.
name: "InfantNet"
input: "dataMR32"
input_shape {
dim: 1
dim: 1
dim: 32
dim: 32
dim: 32
}
#-------------layer group 1---------------
layer {
name: "conv1a"
type: "Convolution"
bottom: "dataMR32"
top: "conv1a"
param {
lr_mult: 1
}
param {
lr_mult: 2
}
convolution_param {
num_output: 32
kernel_size: 3
pad: 1
stride: 1
engine: CAFFE
weight_filler {
type: "gaussian"
std: 0.01
}
bias_filler {
type: "constant"
value: 0
}
}
}
layer {
name: "relu1a"
type: "ReLU"
bottom: "conv1a"
top: "conv1a"
}
layer {
name: "conv1b"
type: "Convolution"
bottom: "conv1a"
top: "conv1b"
param {
lr_mult: 1
}
param {
lr_mult: 2
}
convolution_param {
num_output: 32
kernel_size: 3
pad: 1
stride: 1
engine: CAFFE
weight_filler {
type: "gaussian"
std: 0.01
}
bias_filler {
type: "constant"
value: 0
}
}
}
layer {
name: "relu1b"
type: "ReLU"
bottom: "conv1b"
top: "conv1b"
}
layer {
name: "conv1c"
type: "Convolution"
bottom: "conv1b"
top: "conv1c"
param {
lr_mult: 1
}
param {
lr_mult: 2
}
convolution_param {
num_output: 32
kernel_size: 3
pad: 1
stride: 1
engine: CAFFE
weight_filler {
type: "gaussian"
std: 0.01
}
bias_filler {
type: "constant"
value: 0
}
}
}
layer {
name: "relu1c"
type: "ReLU"
bottom: "conv1c"
top: "conv1c"
}
layer {
name: "pool1"
type: "Pooling"
bottom: "conv1c"
top: "pool1"
pooling_param {
pool: AVE
kernel_size: 3
stride: 2
engine: CAFFE
}
}
#-------------layer group 2---------------
layer {
name: "conv2a"
type: "Convolution"
bottom: "pool1"
top: "conv2a"
param {
lr_mult: 1
}
param {
lr_mult: 2
}
convolution_param {
num_output: 32
kernel_size: 3
pad: 1
stride: 1
engine: CAFFE
weight_filler {
type: "gaussian"
std: 0.01
}
bias_filler {
type: "constant"
value: 0
}
}
}
layer {
name: "relu2a"
type: "ReLU"
bottom: "conv2a"
top: "conv2a"
}
layer {
name: "conv2b"
type: "Convolution"
bottom: "conv2a"
top: "conv2b"
param {
lr_mult: 1
}
param {
lr_mult: 2
}
convolution_param {
num_output: 32
kernel_size: 3
pad: 1
stride: 1
engine: CAFFE
weight_filler {
type: "gaussian"
std: 0.01
}
bias_filler {
type: "constant"
value: 0
}
}
}
layer {
name: "relu2b"
type: "ReLU"
bottom: "conv2b"
top: "conv2b"
}
layer {
name: "pool2"
type: "Pooling"
bottom: "conv2b"
top: "pool2"
pooling_param {
pool: AVE
kernel_size: 3
stride: 2
engine: CAFFE
}
}
#-------------layer group 3---------------
layer {
name: "conv3a"
type: "Convolution"
bottom: "pool2"
top: "conv3a"
param {
lr_mult: 1
}
param {
lr_mult: 2
}
convolution_param {
num_output: 32
kernel_size: 3
pad: 1
stride: 1
engine: CAFFE
weight_filler {
type: "gaussian"
std: 0.01
}
bias_filler {
type: "constant"
value: 0
}
}
}
layer {
name: "relu3a"
type: "ReLU"
bottom: "conv3a"
top: "conv3a"
}
layer {
name: "pool3"
type: "Pooling"
bottom: "conv3a"
top: "pool3"
pooling_param {
pool: AVE
kernel_size: 3
stride: 2
engine: CAFFE
}
}
#------------layer group 4-------------
layer {
name: "deconv4"
type: "Deconvolution"
bottom: "pool3"
top: "deconv4"
param {
lr_mult: 1
}
param {
lr_mult: 2
}
convolution_param {
num_output: 32
#bias_term: false
engine: CAFFE
kernel_size: 4
pad: 1
stride: 2
weight_filler {
type: "gaussian"
std: 0.01
}
}
}
layer {
name: "relu4"
type: "ReLU"
bottom: "deconv4"
top: "deconv4"
}
#------------layer group 5-------------
layer {
name: "deconv5"
type: "Deconvolution"
bottom: "deconv4"
top: "deconv5"
param {
lr_mult: 1
}
param {
lr_mult: 2
}
convolution_param {
num_output: 32
#bias_term: false
engine: CAFFE
kernel_size: 4
pad: 1
stride: 2
weight_filler {
type: "gaussian"
std: 0.01
}
}
}
layer {
name: "relu5"
type: "ReLU"
bottom: "deconv5"
top: "deconv5"
}
#------------layer group 6-------------
layer {
name: "deconv6"
type: "Deconvolution"
bottom: "deconv5"
top: "deconv6"
param {
lr_mult: 1
}
param {
lr_mult: 2
}
convolution_param {
num_output: 4
#bias_term: false
engine: CAFFE
kernel_size: 4
pad: 1
stride: 2
weight_filler {
type: "gaussian"
std: 0.01
}
}
}
layer {
name: "relu6"
type: "ReLU"
bottom: "deconv6"
top: "deconv6"
}
layer {
name: "softmax"
type: "Softmax"
bottom: "deconv6"
top: "softmax"
include: { phase: TEST }
}
#layer {
# name: "loss"
# type: "SoftmaxWithLoss"
# bottom: "deconv6"
# bottom: "dataSeg32"
# top: "loss"
# loss_param {
# ignore_label: -1
# }
# softmax_param {
# axis: 1
# }
# include: { phase: TEST }
#}
#layer {
# name: "frscore"
# type: "Crop"
# bottom: "upscore"
# bottom: "data"
# top: "score"
# crop_param {
# axis: 2
# offset: 19
# }
#}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment