質問編集履歴

2

書式の改善

2021/02/16 05:06

投稿

ban.
ban.

スコア4

test CHANGED
File without changes
test CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
 
4
4
 
5
- (tf114) C:\Users\std09\Downloads\keras-yolo3\keras-yolo3-master>python train.py
5
+ (tf114) C:\keras-yolo3\keras-yolo3-master>python train.py
6
6
 
7
7
  Using TensorFlow backend.
8
8
 
@@ -54,27 +54,141 @@
54
54
 
55
55
  np_resource = np.dtype([("resource", np.ubyte, 1)])
56
56
 
57
+ WARNING:tensorflow:From C:\Users\std09\Anaconda3\envs\tf114\lib\site-packages\keras\backend\tensorflow_backend.py:95: The name tf.reset_default_graph is deprecated. Please use tf.compat.v1.reset_default_graph instead.
58
+
59
+
60
+
61
+ WARNING:tensorflow:From C:\Users\std09\Anaconda3\envs\tf114\lib\site-packages\keras\backend\tensorflow_backend.py:98: The name tf.placeholder_with_default is deprecated. Please use tf.compat.v1.placeholder_with_default instead.
62
+
63
+
64
+
65
+ WARNING:tensorflow:From C:\Users\std09\Anaconda3\envs\tf114\lib\site-packages\keras\backend\tensorflow_backend.py:102: The name tf.get_default_graph is deprecated. Please use tf.compat.v1.get_default_graph instead.
66
+
67
+
68
+
69
+ WARNING:tensorflow:From C:\Users\std09\Anaconda3\envs\tf114\lib\site-packages\keras\backend\tensorflow_backend.py:174: The name tf.get_default_session is deprecated. Please use tf.compat.v1.get_default_session instead.
70
+
71
+
72
+
73
+ WARNING:tensorflow:From C:\Users\std09\Anaconda3\envs\tf114\lib\site-packages\keras\backend\tensorflow_backend.py:181: The name tf.ConfigProto is deprecated. Please use tf.compat.v1.ConfigProto instead.
74
+
75
+
76
+
77
+ 2021-02-16 14:07:39.385171: I tensorflow/core/platform/cpu_feature_guard.cc:142] Your CPU supports instructions that this TensorFlow binary was not compiled to use: AVX2
78
+
79
+ 2021-02-16 14:07:39.389988: I tensorflow/stream_executor/platform/default/dso_loader.cc:42] Successfully opened dynamic library nvcuda.dll
80
+
81
+ 2021-02-16 14:07:39.392874: E tensorflow/stream_executor/cuda/cuda_driver.cc:318] failed call to cuInit: CUDA_ERROR_UNKNOWN: unknown error
82
+
83
+ 2021-02-16 14:07:39.397734: I tensorflow/stream_executor/cuda/cuda_diagnostics.cc:169] retrieving CUDA diagnostic information for host: ELNET09
84
+
85
+ 2021-02-16 14:07:39.399635: I tensorflow/stream_executor/cuda/cuda_diagnostics.cc:176] hostname: ELNET09
86
+
87
+ WARNING:tensorflow:From C:\Users\std09\Anaconda3\envs\tf114\lib\site-packages\keras\backend\tensorflow_backend.py:1919: The name tf.nn.fused_batch_norm is deprecated. Please use tf.compat.v1.nn.fused_batch_norm instead.
88
+
89
+
90
+
91
+ Create YOLOv3 model with 9 anchors and 2 classes.
92
+
93
+ C:\Users\std09\Anaconda3\envs\tf114\lib\site-packages\keras\engine\saving.py:1140: UserWarning: Skipping loading of weights for layer conv2d_59 due to mismatch in shape ((1, 1, 1024, 21) vs (255, 1024, 1, 1)).
94
+
95
+ weight_values[i].shape))
96
+
97
+ C:\Users\std09\Anaconda3\envs\tf114\lib\site-packages\keras\engine\saving.py:1140: UserWarning: Skipping loading of weights for layer conv2d_59 due to mismatch in shape ((21,) vs (255,)).
98
+
99
+ weight_values[i].shape))
100
+
101
+ C:\Users\std09\Anaconda3\envs\tf114\lib\site-packages\keras\engine\saving.py:1140: UserWarning: Skipping loading of weights for layer conv2d_67 due to mismatch in shape ((1, 1, 512, 21) vs (255, 512, 1, 1)).
102
+
103
+ weight_values[i].shape))
104
+
105
+ C:\Users\std09\Anaconda3\envs\tf114\lib\site-packages\keras\engine\saving.py:1140: UserWarning: Skipping loading of weights for layer conv2d_67 due to mismatch in shape ((21,) vs (255,)).
106
+
107
+ weight_values[i].shape))
108
+
109
+ C:\Users\std09\Anaconda3\envs\tf114\lib\site-packages\keras\engine\saving.py:1140: UserWarning: Skipping loading of weights for layer conv2d_75 due to mismatch in shape ((1, 1, 256, 21) vs (255, 256, 1, 1)).
110
+
111
+ weight_values[i].shape))
112
+
113
+ C:\Users\std09\Anaconda3\envs\tf114\lib\site-packages\keras\engine\saving.py:1140: UserWarning: Skipping loading of weights for layer conv2d_75 due to mismatch in shape ((21,) vs (255,)).
114
+
115
+ weight_values[i].shape))
116
+
117
+ Load weights model_data/yolo_weights.h5.
118
+
119
+ Freeze the first 249 layers of total 252 layers.
120
+
121
+ WARNING:tensorflow:From C:\Users\std09\Anaconda3\envs\tf114\lib\site-packages\keras\backend\tensorflow_backend.py:3080: add_dispatch_support.<locals>.wrapper (from tensorflow.python.ops.array_ops) is deprecated and will be removed in a future version.
122
+
123
+ Instructions for updating:
124
+
125
+ Use tf.where in 2.0, which has the same broadcast rule as np.where
126
+
127
+ Train on 42 samples, val on 4 samples, with batch size 32.
128
+
129
+ Epoch 1/50
130
+
57
131
  Traceback (most recent call last):
58
132
 
59
133
  File "train.py", line 190, in <module>
60
134
 
61
135
  _main()
62
136
 
63
- File "train.py", line 33, in _main
137
+ File "train.py", line 65, in _main
64
138
 
65
- freeze_body=2, weights_path='model_data/yolo_weights.h5') # make sure you know what you freeze
139
+ callbacks=[logging, checkpoint])
66
140
 
67
- File "train.py", line 108, in create_model
141
+ File "C:\Users\std09\Anaconda3\envs\tf114\lib\site-packages\keras\legacy\interfaces.py", line 91, in wrapper
68
142
 
69
- K.clear_session() # get a new session
143
+ return func(*args, **kwargs)
70
144
 
71
- File "C:\Users\std09\Anaconda3\envs\tf114\lib\site-packages\keras\backend\tensorflow_backend.py", line 102, in clear_session
145
+ File "C:\Users\std09\Anaconda3\envs\tf114\lib\site-packages\keras\engine\training.py", line 1418, in fit_generator
72
146
 
73
- _GRAPH_LEARNING_PHASES[tf.compat.v1.get_default_graph] = phase
147
+ initial_epoch=initial_epoch)
74
148
 
75
- NameError: name 'phase' is not defined
149
+ File "C:\Users\std09\Anaconda3\envs\tf114\lib\site-packages\keras\engine\training_generator.py", line 181, in fit_generator
76
150
 
151
+ generator_output = next(output_generator)
77
152
 
153
+ File "C:\Users\std09\Anaconda3\envs\tf114\lib\site-packages\keras\utils\data_utils.py", line 709, in get
154
+
155
+ six.reraise(*sys.exc_info())
156
+
157
+ File "C:\Users\std09\Anaconda3\envs\tf114\lib\site-packages\six.py", line 703, in reraise
158
+
159
+ raise value
160
+
161
+ File "C:\Users\std09\Anaconda3\envs\tf114\lib\site-packages\keras\utils\data_utils.py", line 685, in get
162
+
163
+ inputs = self.queue.get(block=True).get()
164
+
165
+ File "C:\Users\std09\Anaconda3\envs\tf114\lib\multiprocessing\pool.py", line 657, in get
166
+
167
+ raise self._value
168
+
169
+ File "C:\Users\std09\Anaconda3\envs\tf114\lib\multiprocessing\pool.py", line 121, in worker
170
+
171
+ result = (True, func(*args, **kwds))
172
+
173
+ File "C:\Users\std09\Anaconda3\envs\tf114\lib\site-packages\keras\utils\data_utils.py", line 626, in next_sample
174
+
175
+ return six.next(_SHARED_SEQUENCES[uid])
176
+
177
+ File "train.py", line 175, in data_generator
178
+
179
+ image, box = get_random_data(annotation_lines[i], input_shape, random=True)
180
+
181
+ File "C:\keras-yolo3\keras-yolo3-master\yolo3\utils.py", line 39, in get_random_data
182
+
183
+ image = Image.open(line[0])
184
+
185
+ File "C:\Users\std09\Anaconda3\envs\tf114\lib\site-packages\PIL\Image.py", line 2904, in open
186
+
187
+ fp = builtins.open(filename, "rb")
188
+
189
+ FileNotFoundError: [Errno 2] No such file or directory: 'image_015'
190
+
191
+ 最後のエラーはやるたびにimage_015の数字が変わります。
78
192
 
79
193
  [参考文献]
80
194
 

1

書式の改善

2021/02/16 05:05

投稿

ban.
ban.

スコア4

test CHANGED
File without changes
test CHANGED
@@ -72,6 +72,8 @@
72
72
 
73
73
  _GRAPH_LEARNING_PHASES[tf.compat.v1.get_default_graph] = phase
74
74
 
75
+ NameError: name 'phase' is not defined
76
+
75
77
 
76
78
 
77
79
  [参考文献]