質問編集履歴
11
追記
test
CHANGED
File without changes
|
test
CHANGED
@@ -36,11 +36,11 @@
|
|
36
36
|
|
37
37
|
### 追記
|
38
38
|
|
39
|
-
caffeをちゃんと入れていなかったので以下を参考に入れましたhttps://mugichoko.hatenablog.com/entry/2017/10/31/044806
|
39
|
+
caffeをちゃんと入れていなかったようだったので以下を参考に入れました。https://mugichoko.hatenablog.com/entry/2017/10/31/044806
|
40
40
|
|
41
41
|
|
42
42
|
|
43
|
-
また、この後いろんなサイトを参考にしながらinputShapeを3 227 227に変更し回してみたところ、エラーが以下のように変わりました。
|
43
|
+
また、この後いろんなサイトを参考にしながらinputShapeを3 227 227に変更しかつ変換したいモデルのある場所で回してみたところ、エラーが以下のように変わりました。
|
44
44
|
|
45
45
|
```
|
46
46
|
|
@@ -60,11 +60,21 @@
|
|
60
60
|
|
61
61
|
```
|
62
62
|
|
63
|
-
該当のファイルがそもそも見つからず、、、caffeの問題なのでしょうか。
|
63
|
+
~~該当のファイルがそもそも見つからず、、、caffeの問題なのでしょうか。
|
64
64
|
|
65
|
-
また、「開けない」と言われたファイルのディレクトリを絶対パスに通すと良いというのを見つけたのでやってみましたが特に変わりはありませんでした。
|
65
|
+
また、「開けない」と言われたファイルのディレクトリを絶対パスに通すと良いというのを見つけたのでやってみましたが特に変わりはありませんでした。~~
|
66
66
|
|
67
|
+
inputNetworkのファイルをtrain_val.prototxtからdeploy.prototxtファイルにしたところ、
|
67
68
|
|
69
|
+
```
|
70
|
+
|
71
|
+
Check failed: count_ == proto.data_size() (34848 vs. 0)
|
72
|
+
|
73
|
+
```
|
74
|
+
|
75
|
+
といったエラーに変わりました。しらべたところ、訓練に用いたcaffeのバージョン(GPU,0.17.0)と今回の変換用のバージョン(CPU,1.0?)が違うとこのように表示されるようでした。
|
76
|
+
|
77
|
+
ですので、GPU版のものを入れようと思うのですが、そのまま入れてしまって大丈夫なのでしょうか。
|
68
78
|
|
69
79
|
### (補足情報)
|
70
80
|
|
10
修正
test
CHANGED
File without changes
|
test
CHANGED
@@ -50,7 +50,13 @@
|
|
50
50
|
|
51
51
|
```
|
52
52
|
|
53
|
+
WARNING: Logging before InitGoogleLogging() is written to STDERR
|
54
|
+
|
55
|
+
I1027 13:37:01.994166 12988 upgrade_proto.cpp:67] Attempting to upgrade input file specified using deprecated input fields: C:\Users\user\AppData\Local\Temp\tmpj05vocvw.prototxt
|
56
|
+
|
57
|
+
(中略)
|
58
|
+
|
53
|
-
RuntimeError: Could not open file C:\Users\user\AppData\Local\Temp\tmp
|
59
|
+
RuntimeError: Could not open file C:\Users\user\AppData\Local\Temp\tmpj05vocvw.prototxt
|
54
60
|
|
55
61
|
```
|
56
62
|
|
9
追記
test
CHANGED
File without changes
|
test
CHANGED
@@ -40,769 +40,25 @@
|
|
40
40
|
|
41
41
|
|
42
42
|
|
43
|
-
また、
|
43
|
+
また、この後いろんなサイトを参考にしながらinputShapeを3 227 227に変更し回してみたところ、エラーが以下のように変わりました。
|
44
44
|
|
45
45
|
```
|
46
46
|
|
47
|
-
(ENV_NAME) C:\Users\user\Desktop\
|
47
|
+
(ENV_NAME) C:\Users\user\Desktop\keras-grad-cam-master\caffemodel>mmconvert --srcFramework caffe --inputWeight SgdAlex30.caffemodel --inputNetwork train_val.prototxt --dstFramework keras --outputModel SgdAlex30.h5 --inputShape 3 227 227
|
48
48
|
|
49
49
|
```
|
50
50
|
|
51
|
+
```
|
51
52
|
|
53
|
+
RuntimeError: Could not open file C:\Users\user\AppData\Local\Temp\tmp_47xrshz.prototxt
|
52
54
|
|
53
55
|
```
|
54
56
|
|
55
|
-
|
57
|
+
該当のファイルがそもそも見つからず、、、caffeの問題なのでしょうか。
|
56
58
|
|
57
|
-
```
|
58
|
-
|
59
|
-
|
59
|
+
また、「開けない」と言われたファイルのディレクトリを絶対パスに通すと良いというのを見つけたのでやってみましたが特に変わりはありませんでした。
|
60
60
|
|
61
61
|
|
62
|
-
|
63
|
-
また、この後入力の方法を「1,3,227,227」から「1 3 227 227」に変更してみたところ、以下のようになりました。
|
64
|
-
|
65
|
-
```
|
66
|
-
|
67
|
-
WARNING: Logging before InitGoogleLogging() is written to STDERR
|
68
|
-
|
69
|
-
I1023 11:42:05.834072 12172 upgrade_proto.cpp:67] Attempting to upgrade input file specified using deprecated input fields: C:\Users\7117115\AppData\Local\Temp\tmp_tb7gdlv.prototxt
|
70
|
-
|
71
|
-
I1023 11:42:05.850147 12172 upgrade_proto.cpp:70] Successfully upgraded file specified using deprecated input fields.
|
72
|
-
|
73
|
-
W1023 11:42:05.850147 12172 upgrade_proto.cpp:72] Note that future Caffe releases will only support input layers and not input fields.
|
74
|
-
|
75
|
-
I1023 11:42:05.893544 12172 net.cpp:51] Initializing net from parameters:
|
76
|
-
|
77
|
-
state {
|
78
|
-
|
79
|
-
phase: TEST
|
80
|
-
|
81
|
-
level: 0
|
82
|
-
|
83
|
-
}
|
84
|
-
|
85
|
-
layer {
|
86
|
-
|
87
|
-
name: "input"
|
88
|
-
|
89
|
-
type: "Input"
|
90
|
-
|
91
|
-
top: "data"
|
92
|
-
|
93
|
-
input_param {
|
94
|
-
|
95
|
-
shape {
|
96
|
-
|
97
|
-
dim: 1
|
98
|
-
|
99
|
-
dim: 1
|
100
|
-
|
101
|
-
dim: 3
|
102
|
-
|
103
|
-
dim: 227
|
104
|
-
|
105
|
-
}
|
106
|
-
|
107
|
-
}
|
108
|
-
|
109
|
-
}
|
110
|
-
|
111
|
-
layer {
|
112
|
-
|
113
|
-
name: "conv1"
|
114
|
-
|
115
|
-
type: "Convolution"
|
116
|
-
|
117
|
-
bottom: "data"
|
118
|
-
|
119
|
-
top: "conv1"
|
120
|
-
|
121
|
-
param {
|
122
|
-
|
123
|
-
lr_mult: 1
|
124
|
-
|
125
|
-
decay_mult: 1
|
126
|
-
|
127
|
-
}
|
128
|
-
|
129
|
-
param {
|
130
|
-
|
131
|
-
lr_mult: 2
|
132
|
-
|
133
|
-
decay_mult: 0
|
134
|
-
|
135
|
-
}
|
136
|
-
|
137
|
-
convolution_param {
|
138
|
-
|
139
|
-
num_output: 96
|
140
|
-
|
141
|
-
kernel_size: 11
|
142
|
-
|
143
|
-
stride: 4
|
144
|
-
|
145
|
-
weight_filler {
|
146
|
-
|
147
|
-
type: "gaussian"
|
148
|
-
|
149
|
-
std: 0.01
|
150
|
-
|
151
|
-
}
|
152
|
-
|
153
|
-
bias_filler {
|
154
|
-
|
155
|
-
type: "constant"
|
156
|
-
|
157
|
-
value: 0
|
158
|
-
|
159
|
-
}
|
160
|
-
|
161
|
-
}
|
162
|
-
|
163
|
-
}
|
164
|
-
|
165
|
-
layer {
|
166
|
-
|
167
|
-
name: "relu1"
|
168
|
-
|
169
|
-
type: "ReLU"
|
170
|
-
|
171
|
-
bottom: "conv1"
|
172
|
-
|
173
|
-
top: "conv1"
|
174
|
-
|
175
|
-
}
|
176
|
-
|
177
|
-
layer {
|
178
|
-
|
179
|
-
name: "norm1"
|
180
|
-
|
181
|
-
type: "LRN"
|
182
|
-
|
183
|
-
bottom: "conv1"
|
184
|
-
|
185
|
-
top: "norm1"
|
186
|
-
|
187
|
-
lrn_param {
|
188
|
-
|
189
|
-
local_size: 5
|
190
|
-
|
191
|
-
alpha: 0.0001
|
192
|
-
|
193
|
-
beta: 0.75
|
194
|
-
|
195
|
-
}
|
196
|
-
|
197
|
-
}
|
198
|
-
|
199
|
-
layer {
|
200
|
-
|
201
|
-
name: "pool1"
|
202
|
-
|
203
|
-
type: "Pooling"
|
204
|
-
|
205
|
-
bottom: "norm1"
|
206
|
-
|
207
|
-
top: "pool1"
|
208
|
-
|
209
|
-
pooling_param {
|
210
|
-
|
211
|
-
pool: MAX
|
212
|
-
|
213
|
-
kernel_size: 3
|
214
|
-
|
215
|
-
stride: 2
|
216
|
-
|
217
|
-
}
|
218
|
-
|
219
|
-
}
|
220
|
-
|
221
|
-
layer {
|
222
|
-
|
223
|
-
name: "conv2"
|
224
|
-
|
225
|
-
type: "Convolution"
|
226
|
-
|
227
|
-
bottom: "pool1"
|
228
|
-
|
229
|
-
top: "conv2"
|
230
|
-
|
231
|
-
param {
|
232
|
-
|
233
|
-
lr_mult: 1
|
234
|
-
|
235
|
-
decay_mult: 1
|
236
|
-
|
237
|
-
}
|
238
|
-
|
239
|
-
param {
|
240
|
-
|
241
|
-
lr_mult: 2
|
242
|
-
|
243
|
-
decay_mult: 0
|
244
|
-
|
245
|
-
}
|
246
|
-
|
247
|
-
convolution_param {
|
248
|
-
|
249
|
-
num_output: 256
|
250
|
-
|
251
|
-
pad: 2
|
252
|
-
|
253
|
-
kernel_size: 5
|
254
|
-
|
255
|
-
group: 2
|
256
|
-
|
257
|
-
weight_filler {
|
258
|
-
|
259
|
-
type: "gaussian"
|
260
|
-
|
261
|
-
std: 0.01
|
262
|
-
|
263
|
-
}
|
264
|
-
|
265
|
-
bias_filler {
|
266
|
-
|
267
|
-
type: "constant"
|
268
|
-
|
269
|
-
value: 0.1
|
270
|
-
|
271
|
-
}
|
272
|
-
|
273
|
-
}
|
274
|
-
|
275
|
-
}
|
276
|
-
|
277
|
-
layer {
|
278
|
-
|
279
|
-
name: "relu2"
|
280
|
-
|
281
|
-
type: "ReLU"
|
282
|
-
|
283
|
-
bottom: "conv2"
|
284
|
-
|
285
|
-
top: "conv2"
|
286
|
-
|
287
|
-
}
|
288
|
-
|
289
|
-
layer {
|
290
|
-
|
291
|
-
name: "norm2"
|
292
|
-
|
293
|
-
type: "LRN"
|
294
|
-
|
295
|
-
bottom: "conv2"
|
296
|
-
|
297
|
-
top: "norm2"
|
298
|
-
|
299
|
-
lrn_param {
|
300
|
-
|
301
|
-
local_size: 5
|
302
|
-
|
303
|
-
alpha: 0.0001
|
304
|
-
|
305
|
-
beta: 0.75
|
306
|
-
|
307
|
-
}
|
308
|
-
|
309
|
-
}
|
310
|
-
|
311
|
-
layer {
|
312
|
-
|
313
|
-
name: "pool2"
|
314
|
-
|
315
|
-
type: "Pooling"
|
316
|
-
|
317
|
-
bottom: "norm2"
|
318
|
-
|
319
|
-
top: "pool2"
|
320
|
-
|
321
|
-
pooling_param {
|
322
|
-
|
323
|
-
pool: MAX
|
324
|
-
|
325
|
-
kernel_size: 3
|
326
|
-
|
327
|
-
stride: 2
|
328
|
-
|
329
|
-
}
|
330
|
-
|
331
|
-
}
|
332
|
-
|
333
|
-
layer {
|
334
|
-
|
335
|
-
name: "conv3"
|
336
|
-
|
337
|
-
type: "Convolution"
|
338
|
-
|
339
|
-
bottom: "pool2"
|
340
|
-
|
341
|
-
top: "conv3"
|
342
|
-
|
343
|
-
param {
|
344
|
-
|
345
|
-
lr_mult: 1
|
346
|
-
|
347
|
-
decay_mult: 1
|
348
|
-
|
349
|
-
}
|
350
|
-
|
351
|
-
param {
|
352
|
-
|
353
|
-
lr_mult: 2
|
354
|
-
|
355
|
-
decay_mult: 0
|
356
|
-
|
357
|
-
}
|
358
|
-
|
359
|
-
convolution_param {
|
360
|
-
|
361
|
-
num_output: 384
|
362
|
-
|
363
|
-
pad: 1
|
364
|
-
|
365
|
-
kernel_size: 3
|
366
|
-
|
367
|
-
weight_filler {
|
368
|
-
|
369
|
-
type: "gaussian"
|
370
|
-
|
371
|
-
std: 0.01
|
372
|
-
|
373
|
-
}
|
374
|
-
|
375
|
-
bias_filler {
|
376
|
-
|
377
|
-
type: "constant"
|
378
|
-
|
379
|
-
value: 0
|
380
|
-
|
381
|
-
}
|
382
|
-
|
383
|
-
}
|
384
|
-
|
385
|
-
}
|
386
|
-
|
387
|
-
layer {
|
388
|
-
|
389
|
-
name: "relu3"
|
390
|
-
|
391
|
-
type: "ReLU"
|
392
|
-
|
393
|
-
bottom: "conv3"
|
394
|
-
|
395
|
-
top: "conv3"
|
396
|
-
|
397
|
-
}
|
398
|
-
|
399
|
-
layer {
|
400
|
-
|
401
|
-
name: "conv4"
|
402
|
-
|
403
|
-
type: "Convolution"
|
404
|
-
|
405
|
-
bottom: "conv3"
|
406
|
-
|
407
|
-
top: "conv4"
|
408
|
-
|
409
|
-
param {
|
410
|
-
|
411
|
-
lr_mult: 1
|
412
|
-
|
413
|
-
decay_mult: 1
|
414
|
-
|
415
|
-
}
|
416
|
-
|
417
|
-
param {
|
418
|
-
|
419
|
-
lr_mult: 2
|
420
|
-
|
421
|
-
decay_mult: 0
|
422
|
-
|
423
|
-
}
|
424
|
-
|
425
|
-
convolution_param {
|
426
|
-
|
427
|
-
num_output: 384
|
428
|
-
|
429
|
-
pad: 1
|
430
|
-
|
431
|
-
kernel_size: 3
|
432
|
-
|
433
|
-
group: 2
|
434
|
-
|
435
|
-
weight_filler {
|
436
|
-
|
437
|
-
type: "gaussian"
|
438
|
-
|
439
|
-
std: 0.01
|
440
|
-
|
441
|
-
}
|
442
|
-
|
443
|
-
bias_filler {
|
444
|
-
|
445
|
-
type: "constant"
|
446
|
-
|
447
|
-
value: 0.1
|
448
|
-
|
449
|
-
}
|
450
|
-
|
451
|
-
}
|
452
|
-
|
453
|
-
}
|
454
|
-
|
455
|
-
layer {
|
456
|
-
|
457
|
-
name: "relu4"
|
458
|
-
|
459
|
-
type: "ReLU"
|
460
|
-
|
461
|
-
bottom: "conv4"
|
462
|
-
|
463
|
-
top: "conv4"
|
464
|
-
|
465
|
-
}
|
466
|
-
|
467
|
-
layer {
|
468
|
-
|
469
|
-
name: "conv5"
|
470
|
-
|
471
|
-
type: "Convolution"
|
472
|
-
|
473
|
-
bottom: "conv4"
|
474
|
-
|
475
|
-
top: "conv5"
|
476
|
-
|
477
|
-
param {
|
478
|
-
|
479
|
-
lr_mult: 1
|
480
|
-
|
481
|
-
decay_mult: 1
|
482
|
-
|
483
|
-
}
|
484
|
-
|
485
|
-
param {
|
486
|
-
|
487
|
-
lr_mult: 2
|
488
|
-
|
489
|
-
decay_mult: 0
|
490
|
-
|
491
|
-
}
|
492
|
-
|
493
|
-
convolution_param {
|
494
|
-
|
495
|
-
num_output: 256
|
496
|
-
|
497
|
-
pad: 1
|
498
|
-
|
499
|
-
kernel_size: 3
|
500
|
-
|
501
|
-
group: 2
|
502
|
-
|
503
|
-
weight_filler {
|
504
|
-
|
505
|
-
type: "gaussian"
|
506
|
-
|
507
|
-
std: 0.01
|
508
|
-
|
509
|
-
}
|
510
|
-
|
511
|
-
bias_filler {
|
512
|
-
|
513
|
-
type: "constant"
|
514
|
-
|
515
|
-
value: 0.1
|
516
|
-
|
517
|
-
}
|
518
|
-
|
519
|
-
}
|
520
|
-
|
521
|
-
}
|
522
|
-
|
523
|
-
layer {
|
524
|
-
|
525
|
-
name: "relu5"
|
526
|
-
|
527
|
-
type: "ReLU"
|
528
|
-
|
529
|
-
bottom: "conv5"
|
530
|
-
|
531
|
-
top: "conv5"
|
532
|
-
|
533
|
-
}
|
534
|
-
|
535
|
-
layer {
|
536
|
-
|
537
|
-
name: "pool5"
|
538
|
-
|
539
|
-
type: "Pooling"
|
540
|
-
|
541
|
-
bottom: "conv5"
|
542
|
-
|
543
|
-
top: "pool5"
|
544
|
-
|
545
|
-
pooling_param {
|
546
|
-
|
547
|
-
pool: MAX
|
548
|
-
|
549
|
-
kernel_size: 3
|
550
|
-
|
551
|
-
stride: 2
|
552
|
-
|
553
|
-
}
|
554
|
-
|
555
|
-
}
|
556
|
-
|
557
|
-
layer {
|
558
|
-
|
559
|
-
name: "fc6"
|
560
|
-
|
561
|
-
type: "InnerProduct"
|
562
|
-
|
563
|
-
bottom: "pool5"
|
564
|
-
|
565
|
-
top: "fc6"
|
566
|
-
|
567
|
-
param {
|
568
|
-
|
569
|
-
lr_mult: 1
|
570
|
-
|
571
|
-
decay_mult: 1
|
572
|
-
|
573
|
-
}
|
574
|
-
|
575
|
-
param {
|
576
|
-
|
577
|
-
lr_mult: 2
|
578
|
-
|
579
|
-
decay_mult: 0
|
580
|
-
|
581
|
-
}
|
582
|
-
|
583
|
-
inner_product_param {
|
584
|
-
|
585
|
-
num_output: 4096
|
586
|
-
|
587
|
-
weight_filler {
|
588
|
-
|
589
|
-
type: "gaussian"
|
590
|
-
|
591
|
-
std: 0.005
|
592
|
-
|
593
|
-
}
|
594
|
-
|
595
|
-
bias_filler {
|
596
|
-
|
597
|
-
type: "constant"
|
598
|
-
|
599
|
-
value: 0.1
|
600
|
-
|
601
|
-
}
|
602
|
-
|
603
|
-
}
|
604
|
-
|
605
|
-
}
|
606
|
-
|
607
|
-
layer {
|
608
|
-
|
609
|
-
name: "relu6"
|
610
|
-
|
611
|
-
type: "ReLU"
|
612
|
-
|
613
|
-
bottom: "fc6"
|
614
|
-
|
615
|
-
top: "fc6"
|
616
|
-
|
617
|
-
}
|
618
|
-
|
619
|
-
layer {
|
620
|
-
|
621
|
-
name: "drop6"
|
622
|
-
|
623
|
-
type: "Dropout"
|
624
|
-
|
625
|
-
bottom: "fc6"
|
626
|
-
|
627
|
-
top: "fc6"
|
628
|
-
|
629
|
-
dropout_param {
|
630
|
-
|
631
|
-
dropout_ratio: 0.5
|
632
|
-
|
633
|
-
}
|
634
|
-
|
635
|
-
}
|
636
|
-
|
637
|
-
layer {
|
638
|
-
|
639
|
-
name: "fc7"
|
640
|
-
|
641
|
-
type: "InnerProduct"
|
642
|
-
|
643
|
-
bottom: "fc6"
|
644
|
-
|
645
|
-
top: "fc7"
|
646
|
-
|
647
|
-
param {
|
648
|
-
|
649
|
-
lr_mult: 1
|
650
|
-
|
651
|
-
decay_mult: 1
|
652
|
-
|
653
|
-
}
|
654
|
-
|
655
|
-
param {
|
656
|
-
|
657
|
-
lr_mult: 2
|
658
|
-
|
659
|
-
decay_mult: 0
|
660
|
-
|
661
|
-
}
|
662
|
-
|
663
|
-
inner_product_param {
|
664
|
-
|
665
|
-
num_output: 4096
|
666
|
-
|
667
|
-
weight_filler {
|
668
|
-
|
669
|
-
type: "gaussian"
|
670
|
-
|
671
|
-
std: 0.005
|
672
|
-
|
673
|
-
}
|
674
|
-
|
675
|
-
bias_filler {
|
676
|
-
|
677
|
-
type: "constant"
|
678
|
-
|
679
|
-
value: 0.1
|
680
|
-
|
681
|
-
}
|
682
|
-
|
683
|
-
}
|
684
|
-
|
685
|
-
}
|
686
|
-
|
687
|
-
layer {
|
688
|
-
|
689
|
-
name: "relu7"
|
690
|
-
|
691
|
-
type: "ReLU"
|
692
|
-
|
693
|
-
bottom: "fc7"
|
694
|
-
|
695
|
-
top: "fc7"
|
696
|
-
|
697
|
-
}
|
698
|
-
|
699
|
-
layer {
|
700
|
-
|
701
|
-
name: "drop7"
|
702
|
-
|
703
|
-
type: "Dropout"
|
704
|
-
|
705
|
-
bottom: "fc7"
|
706
|
-
|
707
|
-
top: "fc7"
|
708
|
-
|
709
|
-
dropout_param {
|
710
|
-
|
711
|
-
dropout_ratio: 0.5
|
712
|
-
|
713
|
-
}
|
714
|
-
|
715
|
-
}
|
716
|
-
|
717
|
-
layer {
|
718
|
-
|
719
|
-
name: "fc8"
|
720
|
-
|
721
|
-
type: "InnerProduct"
|
722
|
-
|
723
|
-
bottom: "fc7"
|
724
|
-
|
725
|
-
top: "fc8"
|
726
|
-
|
727
|
-
param {
|
728
|
-
|
729
|
-
lr_mult: 1
|
730
|
-
|
731
|
-
decay_mult: 1
|
732
|
-
|
733
|
-
}
|
734
|
-
|
735
|
-
param {
|
736
|
-
|
737
|
-
lr_mult: 2
|
738
|
-
|
739
|
-
decay_mult: 0
|
740
|
-
|
741
|
-
}
|
742
|
-
|
743
|
-
inner_product_param {
|
744
|
-
|
745
|
-
num_output: 2
|
746
|
-
|
747
|
-
weight_filler {
|
748
|
-
|
749
|
-
type: "gaussian"
|
750
|
-
|
751
|
-
std: 0.01
|
752
|
-
|
753
|
-
}
|
754
|
-
|
755
|
-
bias_filler {
|
756
|
-
|
757
|
-
type: "constant"
|
758
|
-
|
759
|
-
value: 0
|
760
|
-
|
761
|
-
}
|
762
|
-
|
763
|
-
}
|
764
|
-
|
765
|
-
}
|
766
|
-
|
767
|
-
layer {
|
768
|
-
|
769
|
-
name: "prob"
|
770
|
-
|
771
|
-
type: "Softmax"
|
772
|
-
|
773
|
-
bottom: "fc8"
|
774
|
-
|
775
|
-
top: "prob"
|
776
|
-
|
777
|
-
}
|
778
|
-
|
779
|
-
I1023 11:42:05.895570 12172 layer_factory.cpp:58] Creating layer input
|
780
|
-
|
781
|
-
I1023 11:42:05.971525 12172 net.cpp:84] Creating Layer input
|
782
|
-
|
783
|
-
I1023 11:42:05.971525 12172 net.cpp:380] input -> data
|
784
|
-
|
785
|
-
I1023 11:42:05.981457 12172 net.cpp:122] Setting up input
|
786
|
-
|
787
|
-
I1023 11:42:05.990782 12172 net.cpp:129] Top shape: 1 1 3 227 (681)
|
788
|
-
|
789
|
-
I1023 11:42:05.990782 12172 net.cpp:137] Memory required for data: 2724
|
790
|
-
|
791
|
-
I1023 11:42:05.991809 12172 layer_factory.cpp:58] Creating layer conv1
|
792
|
-
|
793
|
-
I1023 11:42:05.992776 12172 net.cpp:84] Creating Layer conv1
|
794
|
-
|
795
|
-
I1023 11:42:05.994771 12172 net.cpp:406] conv1 <- data
|
796
|
-
|
797
|
-
I1023 11:42:05.994771 12172 net.cpp:380] conv1 -> conv1
|
798
|
-
|
799
|
-
I1023 11:42:05.997732 12172 common.cpp:36] System entropy source not available, using fallback algorithm to generate seed instead.
|
800
|
-
|
801
|
-
F1023 11:42:05.997732 12172 blob.cpp:32] Check failed: shape[i] >= 0 (-1 vs. 0)
|
802
|
-
|
803
|
-
*** Check failure stack trace: ***
|
804
|
-
|
805
|
-
```
|
806
62
|
|
807
63
|
### (補足情報)
|
808
64
|
|
8
追記
test
CHANGED
File without changes
|
test
CHANGED
@@ -48,6 +48,8 @@
|
|
48
48
|
|
49
49
|
```
|
50
50
|
|
51
|
+
|
52
|
+
|
51
53
|
```
|
52
54
|
|
53
55
|
mmconvert: error: argument --inputShape: invalid int value: '1,3,227,227'
|
@@ -58,57 +60,747 @@
|
|
58
60
|
|
59
61
|
|
60
62
|
|
61
|
-
また、この後入力の方法を「1,3,227,227」から「13227227」に変更してみたところ、以下のように
|
62
|
-
|
63
|
-
```
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
-
|
100
|
-
|
101
|
-
|
102
|
-
|
103
|
-
|
104
|
-
|
105
|
-
|
106
|
-
|
107
|
-
|
108
|
-
|
109
|
-
|
110
|
-
|
111
|
-
|
63
|
+
また、この後入力の方法を「1,3,227,227」から「1 3 227 227」に変更してみたところ、以下のようになりました。
|
64
|
+
|
65
|
+
```
|
66
|
+
|
67
|
+
WARNING: Logging before InitGoogleLogging() is written to STDERR
|
68
|
+
|
69
|
+
I1023 11:42:05.834072 12172 upgrade_proto.cpp:67] Attempting to upgrade input file specified using deprecated input fields: C:\Users\7117115\AppData\Local\Temp\tmp_tb7gdlv.prototxt
|
70
|
+
|
71
|
+
I1023 11:42:05.850147 12172 upgrade_proto.cpp:70] Successfully upgraded file specified using deprecated input fields.
|
72
|
+
|
73
|
+
W1023 11:42:05.850147 12172 upgrade_proto.cpp:72] Note that future Caffe releases will only support input layers and not input fields.
|
74
|
+
|
75
|
+
I1023 11:42:05.893544 12172 net.cpp:51] Initializing net from parameters:
|
76
|
+
|
77
|
+
state {
|
78
|
+
|
79
|
+
phase: TEST
|
80
|
+
|
81
|
+
level: 0
|
82
|
+
|
83
|
+
}
|
84
|
+
|
85
|
+
layer {
|
86
|
+
|
87
|
+
name: "input"
|
88
|
+
|
89
|
+
type: "Input"
|
90
|
+
|
91
|
+
top: "data"
|
92
|
+
|
93
|
+
input_param {
|
94
|
+
|
95
|
+
shape {
|
96
|
+
|
97
|
+
dim: 1
|
98
|
+
|
99
|
+
dim: 1
|
100
|
+
|
101
|
+
dim: 3
|
102
|
+
|
103
|
+
dim: 227
|
104
|
+
|
105
|
+
}
|
106
|
+
|
107
|
+
}
|
108
|
+
|
109
|
+
}
|
110
|
+
|
111
|
+
layer {
|
112
|
+
|
113
|
+
name: "conv1"
|
114
|
+
|
115
|
+
type: "Convolution"
|
116
|
+
|
117
|
+
bottom: "data"
|
118
|
+
|
119
|
+
top: "conv1"
|
120
|
+
|
121
|
+
param {
|
122
|
+
|
123
|
+
lr_mult: 1
|
124
|
+
|
125
|
+
decay_mult: 1
|
126
|
+
|
127
|
+
}
|
128
|
+
|
129
|
+
param {
|
130
|
+
|
131
|
+
lr_mult: 2
|
132
|
+
|
133
|
+
decay_mult: 0
|
134
|
+
|
135
|
+
}
|
136
|
+
|
137
|
+
convolution_param {
|
138
|
+
|
139
|
+
num_output: 96
|
140
|
+
|
141
|
+
kernel_size: 11
|
142
|
+
|
143
|
+
stride: 4
|
144
|
+
|
145
|
+
weight_filler {
|
146
|
+
|
147
|
+
type: "gaussian"
|
148
|
+
|
149
|
+
std: 0.01
|
150
|
+
|
151
|
+
}
|
152
|
+
|
153
|
+
bias_filler {
|
154
|
+
|
155
|
+
type: "constant"
|
156
|
+
|
157
|
+
value: 0
|
158
|
+
|
159
|
+
}
|
160
|
+
|
161
|
+
}
|
162
|
+
|
163
|
+
}
|
164
|
+
|
165
|
+
layer {
|
166
|
+
|
167
|
+
name: "relu1"
|
168
|
+
|
169
|
+
type: "ReLU"
|
170
|
+
|
171
|
+
bottom: "conv1"
|
172
|
+
|
173
|
+
top: "conv1"
|
174
|
+
|
175
|
+
}
|
176
|
+
|
177
|
+
layer {
|
178
|
+
|
179
|
+
name: "norm1"
|
180
|
+
|
181
|
+
type: "LRN"
|
182
|
+
|
183
|
+
bottom: "conv1"
|
184
|
+
|
185
|
+
top: "norm1"
|
186
|
+
|
187
|
+
lrn_param {
|
188
|
+
|
189
|
+
local_size: 5
|
190
|
+
|
191
|
+
alpha: 0.0001
|
192
|
+
|
193
|
+
beta: 0.75
|
194
|
+
|
195
|
+
}
|
196
|
+
|
197
|
+
}
|
198
|
+
|
199
|
+
layer {
|
200
|
+
|
201
|
+
name: "pool1"
|
202
|
+
|
203
|
+
type: "Pooling"
|
204
|
+
|
205
|
+
bottom: "norm1"
|
206
|
+
|
207
|
+
top: "pool1"
|
208
|
+
|
209
|
+
pooling_param {
|
210
|
+
|
211
|
+
pool: MAX
|
212
|
+
|
213
|
+
kernel_size: 3
|
214
|
+
|
215
|
+
stride: 2
|
216
|
+
|
217
|
+
}
|
218
|
+
|
219
|
+
}
|
220
|
+
|
221
|
+
layer {
|
222
|
+
|
223
|
+
name: "conv2"
|
224
|
+
|
225
|
+
type: "Convolution"
|
226
|
+
|
227
|
+
bottom: "pool1"
|
228
|
+
|
229
|
+
top: "conv2"
|
230
|
+
|
231
|
+
param {
|
232
|
+
|
233
|
+
lr_mult: 1
|
234
|
+
|
235
|
+
decay_mult: 1
|
236
|
+
|
237
|
+
}
|
238
|
+
|
239
|
+
param {
|
240
|
+
|
241
|
+
lr_mult: 2
|
242
|
+
|
243
|
+
decay_mult: 0
|
244
|
+
|
245
|
+
}
|
246
|
+
|
247
|
+
convolution_param {
|
248
|
+
|
249
|
+
num_output: 256
|
250
|
+
|
251
|
+
pad: 2
|
252
|
+
|
253
|
+
kernel_size: 5
|
254
|
+
|
255
|
+
group: 2
|
256
|
+
|
257
|
+
weight_filler {
|
258
|
+
|
259
|
+
type: "gaussian"
|
260
|
+
|
261
|
+
std: 0.01
|
262
|
+
|
263
|
+
}
|
264
|
+
|
265
|
+
bias_filler {
|
266
|
+
|
267
|
+
type: "constant"
|
268
|
+
|
269
|
+
value: 0.1
|
270
|
+
|
271
|
+
}
|
272
|
+
|
273
|
+
}
|
274
|
+
|
275
|
+
}
|
276
|
+
|
277
|
+
layer {
|
278
|
+
|
279
|
+
name: "relu2"
|
280
|
+
|
281
|
+
type: "ReLU"
|
282
|
+
|
283
|
+
bottom: "conv2"
|
284
|
+
|
285
|
+
top: "conv2"
|
286
|
+
|
287
|
+
}
|
288
|
+
|
289
|
+
layer {
|
290
|
+
|
291
|
+
name: "norm2"
|
292
|
+
|
293
|
+
type: "LRN"
|
294
|
+
|
295
|
+
bottom: "conv2"
|
296
|
+
|
297
|
+
top: "norm2"
|
298
|
+
|
299
|
+
lrn_param {
|
300
|
+
|
301
|
+
local_size: 5
|
302
|
+
|
303
|
+
alpha: 0.0001
|
304
|
+
|
305
|
+
beta: 0.75
|
306
|
+
|
307
|
+
}
|
308
|
+
|
309
|
+
}
|
310
|
+
|
311
|
+
layer {
|
312
|
+
|
313
|
+
name: "pool2"
|
314
|
+
|
315
|
+
type: "Pooling"
|
316
|
+
|
317
|
+
bottom: "norm2"
|
318
|
+
|
319
|
+
top: "pool2"
|
320
|
+
|
321
|
+
pooling_param {
|
322
|
+
|
323
|
+
pool: MAX
|
324
|
+
|
325
|
+
kernel_size: 3
|
326
|
+
|
327
|
+
stride: 2
|
328
|
+
|
329
|
+
}
|
330
|
+
|
331
|
+
}
|
332
|
+
|
333
|
+
layer {
|
334
|
+
|
335
|
+
name: "conv3"
|
336
|
+
|
337
|
+
type: "Convolution"
|
338
|
+
|
339
|
+
bottom: "pool2"
|
340
|
+
|
341
|
+
top: "conv3"
|
342
|
+
|
343
|
+
param {
|
344
|
+
|
345
|
+
lr_mult: 1
|
346
|
+
|
347
|
+
decay_mult: 1
|
348
|
+
|
349
|
+
}
|
350
|
+
|
351
|
+
param {
|
352
|
+
|
353
|
+
lr_mult: 2
|
354
|
+
|
355
|
+
decay_mult: 0
|
356
|
+
|
357
|
+
}
|
358
|
+
|
359
|
+
convolution_param {
|
360
|
+
|
361
|
+
num_output: 384
|
362
|
+
|
363
|
+
pad: 1
|
364
|
+
|
365
|
+
kernel_size: 3
|
366
|
+
|
367
|
+
weight_filler {
|
368
|
+
|
369
|
+
type: "gaussian"
|
370
|
+
|
371
|
+
std: 0.01
|
372
|
+
|
373
|
+
}
|
374
|
+
|
375
|
+
bias_filler {
|
376
|
+
|
377
|
+
type: "constant"
|
378
|
+
|
379
|
+
value: 0
|
380
|
+
|
381
|
+
}
|
382
|
+
|
383
|
+
}
|
384
|
+
|
385
|
+
}
|
386
|
+
|
387
|
+
layer {
|
388
|
+
|
389
|
+
name: "relu3"
|
390
|
+
|
391
|
+
type: "ReLU"
|
392
|
+
|
393
|
+
bottom: "conv3"
|
394
|
+
|
395
|
+
top: "conv3"
|
396
|
+
|
397
|
+
}
|
398
|
+
|
399
|
+
layer {
|
400
|
+
|
401
|
+
name: "conv4"
|
402
|
+
|
403
|
+
type: "Convolution"
|
404
|
+
|
405
|
+
bottom: "conv3"
|
406
|
+
|
407
|
+
top: "conv4"
|
408
|
+
|
409
|
+
param {
|
410
|
+
|
411
|
+
lr_mult: 1
|
412
|
+
|
413
|
+
decay_mult: 1
|
414
|
+
|
415
|
+
}
|
416
|
+
|
417
|
+
param {
|
418
|
+
|
419
|
+
lr_mult: 2
|
420
|
+
|
421
|
+
decay_mult: 0
|
422
|
+
|
423
|
+
}
|
424
|
+
|
425
|
+
convolution_param {
|
426
|
+
|
427
|
+
num_output: 384
|
428
|
+
|
429
|
+
pad: 1
|
430
|
+
|
431
|
+
kernel_size: 3
|
432
|
+
|
433
|
+
group: 2
|
434
|
+
|
435
|
+
weight_filler {
|
436
|
+
|
437
|
+
type: "gaussian"
|
438
|
+
|
439
|
+
std: 0.01
|
440
|
+
|
441
|
+
}
|
442
|
+
|
443
|
+
bias_filler {
|
444
|
+
|
445
|
+
type: "constant"
|
446
|
+
|
447
|
+
value: 0.1
|
448
|
+
|
449
|
+
}
|
450
|
+
|
451
|
+
}
|
452
|
+
|
453
|
+
}
|
454
|
+
|
455
|
+
layer {
|
456
|
+
|
457
|
+
name: "relu4"
|
458
|
+
|
459
|
+
type: "ReLU"
|
460
|
+
|
461
|
+
bottom: "conv4"
|
462
|
+
|
463
|
+
top: "conv4"
|
464
|
+
|
465
|
+
}
|
466
|
+
|
467
|
+
layer {
|
468
|
+
|
469
|
+
name: "conv5"
|
470
|
+
|
471
|
+
type: "Convolution"
|
472
|
+
|
473
|
+
bottom: "conv4"
|
474
|
+
|
475
|
+
top: "conv5"
|
476
|
+
|
477
|
+
param {
|
478
|
+
|
479
|
+
lr_mult: 1
|
480
|
+
|
481
|
+
decay_mult: 1
|
482
|
+
|
483
|
+
}
|
484
|
+
|
485
|
+
param {
|
486
|
+
|
487
|
+
lr_mult: 2
|
488
|
+
|
489
|
+
decay_mult: 0
|
490
|
+
|
491
|
+
}
|
492
|
+
|
493
|
+
convolution_param {
|
494
|
+
|
495
|
+
num_output: 256
|
496
|
+
|
497
|
+
pad: 1
|
498
|
+
|
499
|
+
kernel_size: 3
|
500
|
+
|
501
|
+
group: 2
|
502
|
+
|
503
|
+
weight_filler {
|
504
|
+
|
505
|
+
type: "gaussian"
|
506
|
+
|
507
|
+
std: 0.01
|
508
|
+
|
509
|
+
}
|
510
|
+
|
511
|
+
bias_filler {
|
512
|
+
|
513
|
+
type: "constant"
|
514
|
+
|
515
|
+
value: 0.1
|
516
|
+
|
517
|
+
}
|
518
|
+
|
519
|
+
}
|
520
|
+
|
521
|
+
}
|
522
|
+
|
523
|
+
layer {
|
524
|
+
|
525
|
+
name: "relu5"
|
526
|
+
|
527
|
+
type: "ReLU"
|
528
|
+
|
529
|
+
bottom: "conv5"
|
530
|
+
|
531
|
+
top: "conv5"
|
532
|
+
|
533
|
+
}
|
534
|
+
|
535
|
+
layer {
|
536
|
+
|
537
|
+
name: "pool5"
|
538
|
+
|
539
|
+
type: "Pooling"
|
540
|
+
|
541
|
+
bottom: "conv5"
|
542
|
+
|
543
|
+
top: "pool5"
|
544
|
+
|
545
|
+
pooling_param {
|
546
|
+
|
547
|
+
pool: MAX
|
548
|
+
|
549
|
+
kernel_size: 3
|
550
|
+
|
551
|
+
stride: 2
|
552
|
+
|
553
|
+
}
|
554
|
+
|
555
|
+
}
|
556
|
+
|
557
|
+
layer {
|
558
|
+
|
559
|
+
name: "fc6"
|
560
|
+
|
561
|
+
type: "InnerProduct"
|
562
|
+
|
563
|
+
bottom: "pool5"
|
564
|
+
|
565
|
+
top: "fc6"
|
566
|
+
|
567
|
+
param {
|
568
|
+
|
569
|
+
lr_mult: 1
|
570
|
+
|
571
|
+
decay_mult: 1
|
572
|
+
|
573
|
+
}
|
574
|
+
|
575
|
+
param {
|
576
|
+
|
577
|
+
lr_mult: 2
|
578
|
+
|
579
|
+
decay_mult: 0
|
580
|
+
|
581
|
+
}
|
582
|
+
|
583
|
+
inner_product_param {
|
584
|
+
|
585
|
+
num_output: 4096
|
586
|
+
|
587
|
+
weight_filler {
|
588
|
+
|
589
|
+
type: "gaussian"
|
590
|
+
|
591
|
+
std: 0.005
|
592
|
+
|
593
|
+
}
|
594
|
+
|
595
|
+
bias_filler {
|
596
|
+
|
597
|
+
type: "constant"
|
598
|
+
|
599
|
+
value: 0.1
|
600
|
+
|
601
|
+
}
|
602
|
+
|
603
|
+
}
|
604
|
+
|
605
|
+
}
|
606
|
+
|
607
|
+
layer {
|
608
|
+
|
609
|
+
name: "relu6"
|
610
|
+
|
611
|
+
type: "ReLU"
|
612
|
+
|
613
|
+
bottom: "fc6"
|
614
|
+
|
615
|
+
top: "fc6"
|
616
|
+
|
617
|
+
}
|
618
|
+
|
619
|
+
layer {
|
620
|
+
|
621
|
+
name: "drop6"
|
622
|
+
|
623
|
+
type: "Dropout"
|
624
|
+
|
625
|
+
bottom: "fc6"
|
626
|
+
|
627
|
+
top: "fc6"
|
628
|
+
|
629
|
+
dropout_param {
|
630
|
+
|
631
|
+
dropout_ratio: 0.5
|
632
|
+
|
633
|
+
}
|
634
|
+
|
635
|
+
}
|
636
|
+
|
637
|
+
layer {
|
638
|
+
|
639
|
+
name: "fc7"
|
640
|
+
|
641
|
+
type: "InnerProduct"
|
642
|
+
|
643
|
+
bottom: "fc6"
|
644
|
+
|
645
|
+
top: "fc7"
|
646
|
+
|
647
|
+
param {
|
648
|
+
|
649
|
+
lr_mult: 1
|
650
|
+
|
651
|
+
decay_mult: 1
|
652
|
+
|
653
|
+
}
|
654
|
+
|
655
|
+
param {
|
656
|
+
|
657
|
+
lr_mult: 2
|
658
|
+
|
659
|
+
decay_mult: 0
|
660
|
+
|
661
|
+
}
|
662
|
+
|
663
|
+
inner_product_param {
|
664
|
+
|
665
|
+
num_output: 4096
|
666
|
+
|
667
|
+
weight_filler {
|
668
|
+
|
669
|
+
type: "gaussian"
|
670
|
+
|
671
|
+
std: 0.005
|
672
|
+
|
673
|
+
}
|
674
|
+
|
675
|
+
bias_filler {
|
676
|
+
|
677
|
+
type: "constant"
|
678
|
+
|
679
|
+
value: 0.1
|
680
|
+
|
681
|
+
}
|
682
|
+
|
683
|
+
}
|
684
|
+
|
685
|
+
}
|
686
|
+
|
687
|
+
layer {
|
688
|
+
|
689
|
+
name: "relu7"
|
690
|
+
|
691
|
+
type: "ReLU"
|
692
|
+
|
693
|
+
bottom: "fc7"
|
694
|
+
|
695
|
+
top: "fc7"
|
696
|
+
|
697
|
+
}
|
698
|
+
|
699
|
+
layer {
|
700
|
+
|
701
|
+
name: "drop7"
|
702
|
+
|
703
|
+
type: "Dropout"
|
704
|
+
|
705
|
+
bottom: "fc7"
|
706
|
+
|
707
|
+
top: "fc7"
|
708
|
+
|
709
|
+
dropout_param {
|
710
|
+
|
711
|
+
dropout_ratio: 0.5
|
712
|
+
|
713
|
+
}
|
714
|
+
|
715
|
+
}
|
716
|
+
|
717
|
+
layer {
|
718
|
+
|
719
|
+
name: "fc8"
|
720
|
+
|
721
|
+
type: "InnerProduct"
|
722
|
+
|
723
|
+
bottom: "fc7"
|
724
|
+
|
725
|
+
top: "fc8"
|
726
|
+
|
727
|
+
param {
|
728
|
+
|
729
|
+
lr_mult: 1
|
730
|
+
|
731
|
+
decay_mult: 1
|
732
|
+
|
733
|
+
}
|
734
|
+
|
735
|
+
param {
|
736
|
+
|
737
|
+
lr_mult: 2
|
738
|
+
|
739
|
+
decay_mult: 0
|
740
|
+
|
741
|
+
}
|
742
|
+
|
743
|
+
inner_product_param {
|
744
|
+
|
745
|
+
num_output: 2
|
746
|
+
|
747
|
+
weight_filler {
|
748
|
+
|
749
|
+
type: "gaussian"
|
750
|
+
|
751
|
+
std: 0.01
|
752
|
+
|
753
|
+
}
|
754
|
+
|
755
|
+
bias_filler {
|
756
|
+
|
757
|
+
type: "constant"
|
758
|
+
|
759
|
+
value: 0
|
760
|
+
|
761
|
+
}
|
762
|
+
|
763
|
+
}
|
764
|
+
|
765
|
+
}
|
766
|
+
|
767
|
+
layer {
|
768
|
+
|
769
|
+
name: "prob"
|
770
|
+
|
771
|
+
type: "Softmax"
|
772
|
+
|
773
|
+
bottom: "fc8"
|
774
|
+
|
775
|
+
top: "prob"
|
776
|
+
|
777
|
+
}
|
778
|
+
|
779
|
+
I1023 11:42:05.895570 12172 layer_factory.cpp:58] Creating layer input
|
780
|
+
|
781
|
+
I1023 11:42:05.971525 12172 net.cpp:84] Creating Layer input
|
782
|
+
|
783
|
+
I1023 11:42:05.971525 12172 net.cpp:380] input -> data
|
784
|
+
|
785
|
+
I1023 11:42:05.981457 12172 net.cpp:122] Setting up input
|
786
|
+
|
787
|
+
I1023 11:42:05.990782 12172 net.cpp:129] Top shape: 1 1 3 227 (681)
|
788
|
+
|
789
|
+
I1023 11:42:05.990782 12172 net.cpp:137] Memory required for data: 2724
|
790
|
+
|
791
|
+
I1023 11:42:05.991809 12172 layer_factory.cpp:58] Creating layer conv1
|
792
|
+
|
793
|
+
I1023 11:42:05.992776 12172 net.cpp:84] Creating Layer conv1
|
794
|
+
|
795
|
+
I1023 11:42:05.994771 12172 net.cpp:406] conv1 <- data
|
796
|
+
|
797
|
+
I1023 11:42:05.994771 12172 net.cpp:380] conv1 -> conv1
|
798
|
+
|
799
|
+
I1023 11:42:05.997732 12172 common.cpp:36] System entropy source not available, using fallback algorithm to generate seed instead.
|
800
|
+
|
801
|
+
F1023 11:42:05.997732 12172 blob.cpp:32] Check failed: shape[i] >= 0 (-1 vs. 0)
|
802
|
+
|
803
|
+
*** Check failure stack trace: ***
|
112
804
|
|
113
805
|
```
|
114
806
|
|
7
修正
test
CHANGED
File without changes
|
test
CHANGED
@@ -58,7 +58,7 @@
|
|
58
58
|
|
59
59
|
|
60
60
|
|
61
|
-
また、この後入力の方法を「1,3,227,227」から「13227227」に変更した
|
61
|
+
また、この後入力の方法を「1,3,227,227」から「13227227」に変更してみたところ、以下のようにエラーが変わりました。最後の箇所を読むとheightとwidthを入力する必要があるようです
|
62
62
|
|
63
63
|
```
|
64
64
|
|
6
追記
test
CHANGED
File without changes
|
test
CHANGED
@@ -54,9 +54,65 @@
|
|
54
54
|
|
55
55
|
```
|
56
56
|
|
57
|
-
|
57
|
+
※inputShapeの値はdeploy.prototxtのinput_shapeと同じ値です。
|
58
58
|
|
59
|
+
|
60
|
+
|
61
|
+
また、この後入力の方法を「1,3,227,227」から「13227227」に変更した見たところ、以下のようにエラーが変わりました
|
62
|
+
|
63
|
+
```
|
64
|
+
|
65
|
+
------------------------------------------------------------
|
66
|
+
|
67
|
+
WARNING: PyCaffe not found!
|
68
|
+
|
69
|
+
Falling back to a pure protocol buffer implementation.
|
70
|
+
|
71
|
+
* Conversions will be drastically slower.
|
72
|
+
|
73
|
+
* This backend is UNTESTED!
|
74
|
+
|
75
|
+
------------------------------------------------------------
|
76
|
+
|
77
|
+
|
78
|
+
|
79
|
+
Traceback (most recent call last):
|
80
|
+
|
81
|
+
File "c:\users\user\anaconda3\envs\env_name\lib\runpy.py", line 193, in _run_module_as_main
|
82
|
+
|
83
|
+
"__main__", mod_spec)
|
84
|
+
|
85
|
+
File "c:\users\user\anaconda3\envs\env_name\lib\runpy.py", line 85, in _run_code
|
86
|
+
|
87
|
+
exec(code, run_globals)
|
88
|
+
|
89
|
+
File "C:\Users\user\anaconda3\envs\ENV_NAME\Scripts\mmconvert.exe\__main__.py", line 7, in <module>
|
90
|
+
|
91
|
+
File "c:\users\user\anaconda3\envs\env_name\lib\site-packages\mmdnn\conversion\_script\convert.py", line 89, in _main
|
92
|
+
|
93
|
+
ret = convertToIR._convert(ir_args)
|
94
|
+
|
95
|
+
File "c:\users\user\anaconda3\envs\env_name\lib\site-packages\mmdnn\conversion\_script\convertToIR.py", line 9, in _convert
|
96
|
+
|
97
|
+
transformer = CaffeTransformer(args.network, args.weights, "tensorflow", args.inputShape, phase = args.caffePhase)
|
98
|
+
|
99
|
+
File "c:\users\user\anaconda3\envs\env_name\lib\site-packages\mmdnn\conversion\caffe\transformer.py", line 316, in __init__
|
100
|
+
|
101
|
+
graph = GraphBuilder(def_path, self.input_shape, self.is_train_proto, phase).build()
|
102
|
+
|
103
|
+
File "c:\users\user\anaconda3\envs\env_name\lib\site-packages\mmdnn\conversion\caffe\graph.py", line 447, in build
|
104
|
+
|
105
|
+
graph.compute_output_shapes(self.model)
|
106
|
+
|
107
|
+
File "c:\users\user\anaconda3\envs\env_name\lib\site-packages\mmdnn\conversion\caffe\graph.py", line 271, in compute_output_shapes
|
108
|
+
|
109
|
+
node.output_shape = TensorShape(*NodeKind.compute_output_shape(node))
|
110
|
+
|
111
|
+
TypeError: __new__() missing 2 required positional arguments: 'height' and 'width'
|
112
|
+
|
113
|
+
```
|
114
|
+
|
59
|
-
### 補足情報)
|
115
|
+
### (補足情報)
|
60
116
|
|
61
117
|
|
62
118
|
|
5
修正
test
CHANGED
File without changes
|
test
CHANGED
@@ -54,7 +54,7 @@
|
|
54
54
|
|
55
55
|
```
|
56
56
|
|
57
|
-
おそらくinputShapeの値(
|
57
|
+
おそらくinputShapeの値(deploy.prototxtのinput_shapeと同じ値)が違うのでしょうが、よくわかりません…
|
58
58
|
|
59
59
|
### 補足情報)
|
60
60
|
|
4
修正・修正
test
CHANGED
File without changes
|
test
CHANGED
@@ -8,7 +8,7 @@
|
|
8
8
|
|
9
9
|
https://catdance124.hatenablog.jp/entry/2019/07/30/174908
|
10
10
|
|
11
|
-
こちらを参考にしつつcaffeモデルをkerasモデルに変換しようと試みているのですが、うまくいきません。また、エラーメッセージについても検索にかけましたがよくわかりませんでした
|
11
|
+
こちらを参考にしつつ、DIGITS6.1.1で作成したcaffeモデルをkerasのモデルに変換しようと試みているのですが、うまくいきません。また、エラーメッセージについても検索にかけましたがよくわかりませんでした。
|
12
12
|
|
13
13
|
|
14
14
|
|
@@ -30,19 +30,31 @@
|
|
30
30
|
|
31
31
|
```
|
32
32
|
|
33
|
-
|
34
|
-
|
35
33
|
(ENV_NAME) C:\Users\user>mmconvert --srcFramework caffe --inputWeight C:/~/caffemodel/snapshot_iter_750.caffemodel --inputNetwork C:/~/caffemodel/train_val.prototxt --dstFamework keras --outputModel SGD30.h5 --inputShape 30,3,256,256
|
36
34
|
|
37
35
|
```
|
38
36
|
|
39
|
-
### 追
|
37
|
+
### 追記
|
40
38
|
|
41
|
-
caffeをちゃんと入れていなかったのでhttps://mugichoko.hatenablog.com/entry/2017/10/31/044806
|
39
|
+
caffeをちゃんと入れていなかったので以下を参考に入れましたhttps://mugichoko.hatenablog.com/entry/2017/10/31/044806
|
42
|
-
|
43
|
-
を参考に入れました
|
44
40
|
|
45
41
|
|
42
|
+
|
43
|
+
また、該当ファイルのある場所で変換を行い、また、outputModelを.hdf5にしたりなどしたところ以下のエラーに変わりました。
|
44
|
+
|
45
|
+
```
|
46
|
+
|
47
|
+
(ENV_NAME) C:\Users\user\Desktop\caffe-gradCAM-master\caffemodel>mmconvert --srcFramework caffe --inputWeight SgdAlex30.caffemodel --inputNetwork train_val.prototxt --dstFramework keras --outputModel SGD_Alex30.hdf5 --inputShape 1,3,227,227
|
48
|
+
|
49
|
+
```
|
50
|
+
|
51
|
+
```
|
52
|
+
|
53
|
+
mmconvert: error: argument --inputShape: invalid int value: '1,3,227,227'
|
54
|
+
|
55
|
+
```
|
56
|
+
|
57
|
+
おそらくinputShapeの値(別のファイルに入力されていたinput_shapeからとってきています)が違うのでしょうがよくわかりません…
|
46
58
|
|
47
59
|
### 補足情報)
|
48
60
|
|
3
修正
test
CHANGED
File without changes
|
test
CHANGED
@@ -32,9 +32,15 @@
|
|
32
32
|
|
33
33
|
|
34
34
|
|
35
|
-
(ENV_NAME) C:\Users\user>mmconvert --srcFramework caffe --inputWeight C:/~/caffemodel/snapshot_iter_750.caffemodel --inputNetwork C:/~/caffemodel/train_val.prototxt --dstFamework keras --outputModel SGD30.h5 --inputShape
|
35
|
+
(ENV_NAME) C:\Users\user>mmconvert --srcFramework caffe --inputWeight C:/~/caffemodel/snapshot_iter_750.caffemodel --inputNetwork C:/~/caffemodel/train_val.prototxt --dstFamework keras --outputModel SGD30.h5 --inputShape 30,3,256,256
|
36
36
|
|
37
37
|
```
|
38
|
+
|
39
|
+
### 追加で試してみたこと
|
40
|
+
|
41
|
+
caffeをちゃんと入れていなかったのでhttps://mugichoko.hatenablog.com/entry/2017/10/31/044806
|
42
|
+
|
43
|
+
を参考に入れました
|
38
44
|
|
39
45
|
|
40
46
|
|
@@ -43,11 +49,3 @@
|
|
43
49
|
|
44
50
|
|
45
51
|
python3.5(Anaconda3)上のコマンドプロンプトを使用しています
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
### 追加で試してみたこと
|
50
|
-
|
51
|
-
caffeをちゃんと入れていなかったのでhttps://mugichoko.hatenablog.com/entry/2017/10/31/044806
|
52
|
-
|
53
|
-
を参考に入れました
|
2
追記
test
CHANGED
File without changes
|
test
CHANGED
@@ -43,3 +43,11 @@
|
|
43
43
|
|
44
44
|
|
45
45
|
python3.5(Anaconda3)上のコマンドプロンプトを使用しています
|
46
|
+
|
47
|
+
|
48
|
+
|
49
|
+
### 追加で試してみたこと
|
50
|
+
|
51
|
+
caffeをちゃんと入れていなかったのでhttps://mugichoko.hatenablog.com/entry/2017/10/31/044806
|
52
|
+
|
53
|
+
を参考に入れました
|
1
追記
test
CHANGED
File without changes
|
test
CHANGED
@@ -8,7 +8,7 @@
|
|
8
8
|
|
9
9
|
https://catdance124.hatenablog.jp/entry/2019/07/30/174908
|
10
10
|
|
11
|
-
こちらを参考にしつつcaffeモデルをkerasモデルに変換しようと試みているのですが、うまくいきません。
|
11
|
+
こちらを参考にしつつcaffeモデルをkerasモデルに変換しようと試みているのですが、うまくいきません。また、エラーメッセージについても検索にかけましたがよくわかりませんでした
|
12
12
|
|
13
13
|
|
14
14
|
|