Advertisement
Guest User

Untitled

a guest
Mar 24th, 2017
109
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 4.63 KB | None | 0 0
  1. name: "WSDDN"
  2. layer {
  3. name: 'data'
  4. type: 'Python'
  5. top: 'data'
  6. top: 'rois'
  7. top: 'binarylabel'
  8. top: 'boxscores'
  9. python_param {
  10. module: 'roi_data_layer.layer'
  11. layer: 'RoIWeakDataLayer'
  12. param_str: "'num_classes': 21"
  13. }
  14. }
  15. ##################################
  16. layer {
  17. name: "conv1"
  18. type: "Convolution"
  19. bottom: "data"
  20. top: "conv1"
  21. param { lr_mult: 0 decay_mult: 0 }
  22. param { lr_mult: 0 decay_mult: 0 }
  23. convolution_param {
  24. num_output: 96
  25. kernel_size: 7
  26. stride: 2
  27. }
  28. }
  29. layer {
  30. name: "relu1"
  31. type: "ReLU"
  32. bottom: "conv1"
  33. top: "conv1"
  34. }
  35. layer {
  36. name: "norm1"
  37. type: "LRN"
  38. bottom: "conv1"
  39. top: "norm1"
  40. lrn_param {
  41. local_size: 5
  42. alpha: 0.0005
  43. beta: 0.75
  44. k: 2
  45. }
  46. }
  47. layer {
  48. name: "pool1"
  49. type: "Pooling"
  50. bottom: "norm1"
  51. top: "pool1"
  52. pooling_param {
  53. pool: MAX
  54. kernel_size: 3
  55. stride: 2
  56. }
  57. }
  58. layer {
  59. name: "conv2"
  60. type: "Convolution"
  61. bottom: "pool1"
  62. top: "conv2"
  63. param {
  64. lr_mult: 1
  65. }
  66. param {
  67. lr_mult: 2
  68. }
  69. convolution_param {
  70. num_output: 256
  71. pad: 1
  72. kernel_size: 5
  73. stride: 2
  74. }
  75. }
  76. layer {
  77. name: "relu2"
  78. type: "ReLU"
  79. bottom: "conv2"
  80. top: "conv2"
  81. }
  82. layer {
  83. name: "norm2"
  84. type: "LRN"
  85. bottom: "conv2"
  86. top: "norm2"
  87. lrn_param {
  88. local_size: 5
  89. alpha: 0.0005
  90. beta: 0.75
  91. k: 2
  92. }
  93. }
  94. layer {
  95. name: "pool2"
  96. type: "Pooling"
  97. bottom: "norm2"
  98. top: "pool2"
  99. pooling_param {
  100. pool: MAX
  101. kernel_size: 3
  102. stride: 2
  103. }
  104. }
  105. layer {
  106. name: "conv3"
  107. type: "Convolution"
  108. bottom: "pool2"
  109. top: "conv3"
  110. param {
  111. lr_mult: 1
  112. }
  113. param {
  114. lr_mult: 2
  115. }
  116. convolution_param {
  117. num_output: 512
  118. pad: 1
  119. kernel_size: 3
  120. }
  121. }
  122. layer {
  123. name: "relu3"
  124. type: "ReLU"
  125. bottom: "conv3"
  126. top: "conv3"
  127. }
  128. layer {
  129. name: "conv4"
  130. type: "Convolution"
  131. bottom: "conv3"
  132. top: "conv4"
  133. param {
  134. lr_mult: 1
  135. }
  136. param {
  137. lr_mult: 2
  138. }
  139. convolution_param {
  140. num_output: 512
  141. pad: 1
  142. kernel_size: 3
  143. }
  144. }
  145. layer {
  146. name: "relu4"
  147. type: "ReLU"
  148. bottom: "conv4"
  149. top: "conv4"
  150. }
  151. layer {
  152. name: "conv5"
  153. type: "Convolution"
  154. bottom: "conv4"
  155. top: "conv5"
  156. param {
  157. lr_mult: 1
  158. }
  159. param {
  160. lr_mult: 2
  161. }
  162. convolution_param {
  163. num_output: 512
  164. pad: 1
  165. kernel_size: 3
  166. }
  167. }
  168. layer {
  169. name: "relu5"
  170. type: "ReLU"
  171. bottom: "conv5"
  172. top: "conv5"
  173. }
  174. layer {
  175. name: "roi_pool5"
  176. type: "ROIPooling"
  177. bottom: "conv5"
  178. bottom: "rois"
  179. top: "pool5"
  180. roi_pooling_param {
  181. pooled_w: 6
  182. pooled_h: 6
  183. spatial_scale: 0.0625 # 1/16
  184. }
  185. }
  186. layer {
  187. name: "fc6"
  188. type: "InnerProduct"
  189. bottom: "pool5"
  190. top: "fc6"
  191. param {
  192. lr_mult: 1
  193. }
  194. param {
  195. lr_mult: 2
  196. }
  197. inner_product_param {
  198. num_output: 4096
  199. }
  200. }
  201. layer {
  202. name: "relu6"
  203. type: "ReLU"
  204. bottom: "fc6"
  205. top: "fc6"
  206. }
  207. layer {
  208. name: "drop6"
  209. type: "Dropout"
  210. bottom: "fc6"
  211. top: "fc6"
  212. dropout_param {
  213. dropout_ratio: 0.5
  214. }
  215. }
  216. layer {
  217. name: "fc7"
  218. type: "InnerProduct"
  219. bottom: "fc6"
  220. top: "fc7"
  221. param {
  222. lr_mult: 1
  223. }
  224. param {
  225. lr_mult: 2
  226. }
  227. inner_product_param {
  228. num_output: 1024
  229. }
  230. }
  231. layer {
  232. name: "relu7"
  233. type: "ReLU"
  234. bottom: "fc7"
  235. top: "fc7"
  236. }
  237. layer {
  238. name: "drop7"
  239. type: "Dropout"
  240. bottom: "fc7"
  241. top: "fc7"
  242. dropout_param {
  243. dropout_ratio: 0.5
  244. }
  245. }
  246. layer {
  247. name: "cls_score"
  248. type: "InnerProduct"
  249. bottom: "fc7"
  250. top: "classification_prob"
  251. param {
  252. lr_mult: 1
  253. }
  254. param {
  255. lr_mult: 2
  256. }
  257. inner_product_param {
  258. num_output: 20
  259. weight_filler {
  260. type: "gaussian"
  261. std: 0.01
  262. }
  263. bias_filler {
  264. type: "constant"
  265. value: 0
  266. }
  267. }
  268. }
  269. layer {
  270. name: "det_score"
  271. type: "InnerProduct"
  272. bottom: "fc7"
  273. top: "detection_prob"
  274. param {
  275. lr_mult: 1
  276. }
  277. param {
  278. lr_mult: 2
  279. }
  280. inner_product_param {
  281. num_output: 20
  282. weight_filler {
  283. type: "gaussian"
  284. std: 0.01
  285. }
  286. bias_filler {
  287. type: "constant"
  288. value: 0
  289. }
  290. }
  291. }
  292.  
  293.  
  294.  
  295.  
  296. ##################################
  297. layer {
  298. name: "eltwise-prod"
  299. type: "Eltwise"
  300. bottom: "classification_prob"
  301. bottom: "detection_prob"
  302. top: "cls_prob"
  303. eltwise_param { operation: PROD }
  304. }
  305.  
  306. layer {
  307. name: 'reshape'
  308. type: 'Python'
  309. bottom: 'cls_prob'
  310. top: 'cls_prob_reshaped'
  311. python_param {
  312. module: 'roi_data_layer.layer'
  313. layer: 'SecretAssignmentLayer'
  314. }
  315. }
  316. layer {
  317. name: "WeakPred"
  318. type: "Reduction"
  319. bottom: "cls_prob_reshaped"
  320. top: "weakpred"
  321. reduction_param {
  322. operation: SUM
  323. axis: 2
  324. }
  325. }
  326.  
  327. #weakpred is of dimensions 1 x Nclasses = 1x20
  328. ########## Loss section ##########
  329. layer {
  330. name: 'WsddnLoss'
  331. type: 'Python'
  332. bottom: 'weakpred'
  333. bottom: 'binarylabel'
  334. top: 'loss'
  335. python_param {
  336. module: 'roi_data_layer.layer'
  337. layer: 'WSDDNLoss'
  338. }
  339. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement