Darkflow: خطأ تدريب جديد لمجموعة البيانات - "AttributeError: الكائن 'NoneType' ليس له سمة 'شكل'"

تم إنشاؤها على ٣٠ مايو ٢٠١٧  ·  23تعليقات  ·  مصدر: thtrieu/darkflow

مرحبا،

أنا أقوم بتدريب مجموعة بيانات جديدة. ومع ذلك ، يتم تشغيل التدريب دائمًا لبضع خطوات وفجأة يواجه الخطأ التالي: "AttributeError: كائن 'NoneType' ليس له سمة 'شكل'". أعتقد أن تنسيق التعليق التوضيحي واسم الملف في ملف التعليق التوضيحي صحيحان لأن التدريب قادر على العمل لبضع خطوات وأقوم بتشغيل الأفكار حول كيفية استكشاف المزيد من الأخطاء وإصلاحها.

نقدر أي أفكار أو تساعد في هذا.

شكرا لك.

root<strong i="9">@dd84391fd870</strong>:/ml/darkflow# flow --model cfg/tiny-yolo-new.cfg --train --dataset "../data/new/JPEGImages" --annotation "../data/new/Annotations"

Parsing cfg/tiny-yolo-new.cfg
Loading None ...
Finished in 0.00011324882507324219s

Building net ...
Source | Train? | Layer description                | Output size
-------+--------+----------------------------------+---------------
       |        | input                            | (?, 416, 416, 3)
 Init  |  Yep!  | conv 3x3p1_1  +bnorm  leaky      | (?, 416, 416, 16)
 Load  |  Yep!  | maxp 2x2p0_2                     | (?, 208, 208, 16)
 Init  |  Yep!  | conv 3x3p1_1  +bnorm  leaky      | (?, 208, 208, 32)
 Load  |  Yep!  | maxp 2x2p0_2                     | (?, 104, 104, 32)
 Init  |  Yep!  | conv 3x3p1_1  +bnorm  leaky      | (?, 104, 104, 64)
 Load  |  Yep!  | maxp 2x2p0_2                     | (?, 52, 52, 64)
 Init  |  Yep!  | conv 3x3p1_1  +bnorm  leaky      | (?, 52, 52, 128)
 Load  |  Yep!  | maxp 2x2p0_2                     | (?, 26, 26, 128)
 Init  |  Yep!  | conv 3x3p1_1  +bnorm  leaky      | (?, 26, 26, 256)
 Load  |  Yep!  | maxp 2x2p0_2                     | (?, 13, 13, 256)
 Init  |  Yep!  | conv 3x3p1_1  +bnorm  leaky      | (?, 13, 13, 512)
 Load  |  Yep!  | maxp 2x2p0_1                     | (?, 13, 13, 512)
 Init  |  Yep!  | conv 3x3p1_1  +bnorm  leaky      | (?, 13, 13, 1024)
 Init  |  Yep!  | conv 3x3p1_1  +bnorm  leaky      | (?, 13, 13, 1024)
 Init  |  Yep!  | conv 1x1p0_1    linear           | (?, 13, 13, 40)
-------+--------+----------------------------------+---------------
Running entirely on CPU
cfg/tiny-yolo-new.cfg loss hyper-parameters:
    H       = 13
    W       = 13
    box     = 5
    classes = 3
    scales  = [1.0, 5.0, 1.0, 1.0]
Building cfg/tiny-yolo-new.cfg loss
Building cfg/tiny-yolo-new.cfg train op
W tensorflow/core/platform/cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use SSE3 instructions, but these are available on your machine and could speed up CPU computations.
W tensorflow/core/platform/cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use SSE4.1 instructions, but these are available on your machine and could speed up CPU computations.
W tensorflow/core/platform/cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use SSE4.2 instructions, but these are available on your machine and could speed up CPU computations.
Finished in 7.207982778549194s

Enter training ...

cfg/tiny-yolo-new.cfg parsing ../data/new/Annotations
Parsing for ['tank', 'truck', 'apc'] 
[====================>]100%  000296.xml
Statistics:
apc: 48
tank: 70
truck: 24
Dataset size: 130
Dataset of 130 instance(s)
Training statistics: 
    Learning rate : 1e-05
    Batch size    : 16
    Epoch number  : 1000
    Backup every  : 2000
step 1 - loss 106.16172790527344 - moving ave loss 106.16172790527344
step 2 - loss 106.1773681640625 - moving ave loss 106.16329193115234
step 3 - loss 106.09341430664062 - moving ave loss 106.15630416870117
step 4 - loss 106.24054718017578 - moving ave loss 106.16472846984863
step 5 - loss 106.12216186523438 - moving ave loss 106.1604718093872
step 6 - loss 106.24075317382812 - moving ave loss 106.1684999458313
Traceback (most recent call last):
  File "/usr/local/bin/flow", line 6, in <module>
    cliHandler(sys.argv)
  File "/usr/local/lib/python3.5/dist-packages/darkflow/cli.py", line 29, in cliHandler
    print('Enter training ...'); tfnet.train()
  File "/usr/local/lib/python3.5/dist-packages/darkflow/net/flow.py", line 37, in train
    for i, (x_batch, datum) in enumerate(batches):
  File "/usr/local/lib/python3.5/dist-packages/darkflow/net/yolo/data.py", line 113, in shuffle
    inp, new_feed = self._batch(train_instance)
  File "/usr/local/lib/python3.5/dist-packages/darkflow/net/yolov2/data.py", line 27, in _batch
    img = self.preprocess(path, allobj)
  File "/usr/local/lib/python3.5/dist-packages/darkflow/net/yolo/predict.py", line 61, in preprocess
    result = imcv2_affine_trans(im)
  File "/usr/local/lib/python3.5/dist-packages/darkflow/utils/im_transform.py", line 19, in imcv2_affine_trans
    h, w, c = im.shape
AttributeError: 'NoneType' object has no attribute 'shape'

التعليق الأكثر فائدة

لقد واجهت هذا في الماضي. هناك احتمال كبير بأن بعض ملفات .xml أو .jpg لم يتم تسميتها / تكوينها بشكل صحيح. طريقة واحدة لتصحيح الخطأ هو إضافة

print(jpg)

بعد هذا السطر: https://github.com/thtrieu/darkflow/blob/master/darkflow/net/yolov2/data.py#L26

لذلك ستتمكن من رؤية اسم الملف التالف والتحقيق في إما .xml أو .jpg .

ال 23 كومينتر

تحقق من ملفات xml الخاصة بك ، هل يتضمن اسم الملف امتداد صورك؟

نعم ، اسم الملف يتضمن امتداد صوري: jpg.

يوجد أدناه أحد ملفات xml:

<annotation>
  <folder>JPEGImages</folder>
  <filename>/ml/data/new/JPEGImages/000004.jpg</filename>
  <source>
    <database>Unknown</database>
  </source>
  <size>
    <width>386</width>
    <height>257</height>
    <depth>3</depth>
  </size>
  <segmented>0</segmented>
  <object>
    <name>tank</name>
    <pose>Unspecified</pose>
    <truncated>0</truncated>
    <difficult>0</difficult>
    <bndbox>
      <xmin>80</xmin>
      <ymin>51</ymin>
      <xmax>357</xmax>
      <ymax>220</ymax>
    </bndbox>
  </object>
</annotation>

@ wendq86 بالنظر إلى أن هذا لا يعمل - هل يمكنك محاولة وضع أسماء الملفات بدون المسار ، على سبيل المثال <filename>000004.jpg</filename> ومعرفة ما إذا كان ذلك يغير شيئًا عند محاولة التدريب؟

abagshaw شكرا على الاقتراح. حاولت وضع أسماء الملفات بدون المسار وما زلت أواجه نفس الخطأ.

أي أفكار أخرى؟

root<strong i="8">@154b72514519</strong>:/ml/darkflow# flow --model cfg/tiny-yolo-new.cfg --train --dataset "/ml/data/new/JPEGImages" --annotation "/ml/data/new/Annotations"

Parsing cfg/tiny-yolo-new.cfg
Loading None ...
Finished in 0.00011515617370605469s

Building net ...
Source | Train? | Layer description                | Output size
-------+--------+----------------------------------+---------------
       |        | input                            | (?, 416, 416, 3)
 Init  |  Yep!  | conv 3x3p1_1  +bnorm  leaky      | (?, 416, 416, 16)
 Load  |  Yep!  | maxp 2x2p0_2                     | (?, 208, 208, 16)
 Init  |  Yep!  | conv 3x3p1_1  +bnorm  leaky      | (?, 208, 208, 32)
 Load  |  Yep!  | maxp 2x2p0_2                     | (?, 104, 104, 32)
 Init  |  Yep!  | conv 3x3p1_1  +bnorm  leaky      | (?, 104, 104, 64)
 Load  |  Yep!  | maxp 2x2p0_2                     | (?, 52, 52, 64)
 Init  |  Yep!  | conv 3x3p1_1  +bnorm  leaky      | (?, 52, 52, 128)
 Load  |  Yep!  | maxp 2x2p0_2                     | (?, 26, 26, 128)
 Init  |  Yep!  | conv 3x3p1_1  +bnorm  leaky      | (?, 26, 26, 256)
 Load  |  Yep!  | maxp 2x2p0_2                     | (?, 13, 13, 256)
 Init  |  Yep!  | conv 3x3p1_1  +bnorm  leaky      | (?, 13, 13, 512)
 Load  |  Yep!  | maxp 2x2p0_1                     | (?, 13, 13, 512)
 Init  |  Yep!  | conv 3x3p1_1  +bnorm  leaky      | (?, 13, 13, 1024)
 Init  |  Yep!  | conv 3x3p1_1  +bnorm  leaky      | (?, 13, 13, 1024)
 Init  |  Yep!  | conv 1x1p0_1    linear           | (?, 13, 13, 40)
-------+--------+----------------------------------+---------------
Running entirely on CPU
cfg/tiny-yolo-new.cfg loss hyper-parameters:
    H       = 13
    W       = 13
    box     = 5
    classes = 3
    scales  = [1.0, 5.0, 1.0, 1.0]
Building cfg/tiny-yolo-new.cfg loss
Building cfg/tiny-yolo-new.cfg train op
W tensorflow/core/platform/cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use SSE3 instructions, but these are available on your machine and could speed up CPU computations.
W tensorflow/core/platform/cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use SSE4.1 instructions, but these are available on your machine and could speed up CPU computations.
W tensorflow/core/platform/cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use SSE4.2 instructions, but these are available on your machine and could speed up CPU computations.
Finished in 6.813853979110718s

Enter training ...

cfg/tiny-yolo-new.cfg parsing /ml/data/new/Annotations
Parsing for ['tank', 'truck', 'apc'] 
[====================>]100%  000296.xml
Statistics:
tank: 70
truck: 24
apc: 48
Dataset size: 130
Dataset of 130 instance(s)
Training statistics: 
    Learning rate : 1e-05
    Batch size    : 16
    Epoch number  : 1000
    Backup every  : 2000
step 1 - loss 105.96209716796875 - moving ave loss 105.96209716796875
step 2 - loss 105.95611572265625 - moving ave loss 105.9614990234375
step 3 - loss 105.87786865234375 - moving ave loss 105.95313598632812
Traceback (most recent call last):
  File "/usr/local/bin/flow", line 6, in <module>
    cliHandler(sys.argv)
  File "/usr/local/lib/python3.5/dist-packages/darkflow/cli.py", line 29, in cliHandler
    print('Enter training ...'); tfnet.train()
  File "/usr/local/lib/python3.5/dist-packages/darkflow/net/flow.py", line 37, in train
    for i, (x_batch, datum) in enumerate(batches):
  File "/usr/local/lib/python3.5/dist-packages/darkflow/net/yolo/data.py", line 113, in shuffle
    inp, new_feed = self._batch(train_instance)
  File "/usr/local/lib/python3.5/dist-packages/darkflow/net/yolov2/data.py", line 27, in _batch
    img = self.preprocess(path, allobj)
  File "/usr/local/lib/python3.5/dist-packages/darkflow/net/yolo/predict.py", line 61, in preprocess
    result = imcv2_affine_trans(im)
  File "/usr/local/lib/python3.5/dist-packages/darkflow/utils/im_transform.py", line 19, in imcv2_affine_trans
    h, w, c = im.shape
AttributeError: 'NoneType' object has no attribute 'shape'

@ wendq86 الشيء الغريب أنه لم يخطئ في الخطوة الأولى ... مما قد يشير إلى أن بعض ملفات .xml تم تكوينها بشكل صحيح والبعض الآخر ليس كذلك؟ هل أنت متأكد بنسبة 100٪ أن _ جميع الملفات تستخدم التنسيق <filename>000004.jpg</filename> . هل هناك احتمال أن يكون واحدًا (أو أكثر منهم) غير مهيأ بشكل صحيح؟ لست متأكدًا من كيفية تعديل التنسيق لجميع هذه الملفات ... ولكن ربما إذا كنت تستخدم أداة لتعديل عدد كبير من الملفات ، فقد تفقد بعضها؟

الشيء الآخر الوحيد الذي يمكنني التفكير فيه هو أنه ربما تمت إزالة بعض الصور من /ml/data/new/JPEGImages ولكن لم تتم إزالة ملفاتهم .xml من /ml/data/new/Annotations ؟ هل يوجد نفس عدد ملفات .xml في /ml/data/new/Annotations حيث توجد صور في /ml/data/new/JPEGImages ؟

لقد واجهت هذا في الماضي. هناك احتمال كبير بأن بعض ملفات .xml أو .jpg لم يتم تسميتها / تكوينها بشكل صحيح. طريقة واحدة لتصحيح الخطأ هو إضافة

print(jpg)

بعد هذا السطر: https://github.com/thtrieu/darkflow/blob/master/darkflow/net/yolov2/data.py#L26

لذلك ستتمكن من رؤية اسم الملف التالف والتحقيق في إما .xml أو .jpg .

شكرا abagshaw و @ thtrieu! لقد وجدت سبب المشكلة من خلال كتابة برنامج نصي بيثون لتحليل ملفات xml للتحقق من قيمة العرض والارتفاع و ymin و ymax و xmin و xmax. ترجع المشكلة إلى ملفي jpg لا يمكن تحميلهما بشكل صحيح بواسطة opencv ، مما أدى إلى تحديد العرض والارتفاع بـ 0 في ملفات xml المكتوبة بواسطة labelImg.

اقتراح thtrieu مفيد للغاية. لم أستخدم الطباعة لمعرفة المشكلة .jpg أو .xml.
بالنسبة لأي شخص يبدأ في استخدام Darkflow ، ما عليك سوى التأكد مما إذا كان يعمل في بيئتك أم لا. لقد توصلت إلى استنتاج صغير هنا ، بسبب المشاكل التي توصلت إليها:

  1. استخدام البيانات من darkflow-master / test / training / الشروح و ... / الصور ، لذلك لا تحتاج إلى التفكير في أداة VOCformat. لديك ملفين .xml هنا. (1.xml ، 2.xml)
  2. اصنع _test_labels.txt_ الخاص بك ، ضع ثلاثة أسماء للفئات بسبب البيانات (صورتان فقط لركوب الخيل وركوب الدراجة ، يمكنك الحصول على اسم الفصل من .xml ، فقط افتحها وقم بسحبها).
    شخص
    دراجة
    حصان
  3. قم بتغيير _classes_ nad _filters_ في ملف .cfg ، وعليك تغيير اسم * .cfg ، ومن الحكمة أن تحدث بعض المشكلات الأخرى ، ولا تقم بتغيير الأوزان. التي تريد استخدامها ، وإلا ستحدث مشكلة أخرى.
  4. قم بتشغيل الكود التالي للتحقق مما إذا كان يعمل في بيئتك أم لا.
    flow --model ../tiny-yolo-voc-try.cfg --load ../tiny-yolo-voc.weights --labels ../test_labels.txt --train --annotation ../annotations --dataset ../images --gpu 1.0

wendq86 هل يمكنك مشاركتنا السيناريو الخاص بك من فضلك!

لقد واجهت هذا في الماضي. هناك احتمال كبير بأن بعض ملفات .xml أو .jpg لم يتم تسميتها / تكوينها بشكل صحيح. طريقة واحدة لتصحيح الخطأ هو إضافة

print(jpg)

بعد هذا السطر: https://github.com/thtrieu/darkflow/blob/master/darkflow/net/yolov2/data.py#L26

لذلك ستتمكن من رؤية اسم الملف التالف والتحقيق في إما .xml أو .jpg .

كيف يمكنني حل المشكلة إذا كانت ملفات jpeg؟ واجهت نفس المشكلة وقمت بتشغيل البيان المطبوع.

حصلت على هذا الناتج:

cfg/yolov2-tiny-c1v2.cfg parsing lung_train/annotations
Parsing for ['Opacity']
[====================>]100%  012a5620-d082-4bb8-9b3b-e72d8938000c.xml
Statistics:
Opacity: 11
Dataset size: 6
Dataset of 6 instance(s)
**010ccb9f-6d46-4380-af11-84f87397a1b8.jpg
00c0b293-48e7-4e16-ac76-9269ba535a62**

لا أعرف بالضبط ماذا يعني ذلك ، بخلاف أن ملف الصورة الثاني لا يحتوي على jpg بعده.

Dataset size: 10
Dataset of 10 instance(s)
Traceback (most recent call last):
  File "flow", line 6, in <module>
    cliHandler(sys.argv)
  File "/content/darkflow/darkflow/cli.py", line 33, in cliHandler
    print('Enter training ...'); tfnet.train()
  File "/content/darkflow/darkflow/net/flow.py", line 39, in train
    for i, (x_batch, datum) in enumerate(batches):
  File "/content/darkflow/darkflow/net/yolo/data.py", line 114, in shuffle
    inp, new_feed = self._batch(train_instance)
  File "/content/darkflow/darkflow/net/yolov2/data.py", line 28, in _batch
    img = self.preprocess(path, allobj)
  File "/content/darkflow/darkflow/net/yolo/predict.py", line 62, in preprocess
    result = imcv2_affine_trans(im)
  File "/content/darkflow/darkflow/utils/im_transform.py", line 20, in imcv2_affine_trans
    h, w, c = im.shape
AttributeError: 'NoneType' object has no attribute 'shape'

الحصول على هذا الخطأ كيفية إصلاحه الرجاء المساعدة

@ wendq86 بالنظر إلى أن هذا لا يعمل - هل يمكنك محاولة وضع أسماء الملفات بدون المسار ، على سبيل المثال <filename>000004.jpg</filename> ومعرفة ما إذا كان ذلك يغير شيئًا عند محاولة التدريب؟

هذا عمل لي

مرحبًا ، لقد واجهت نفس المشكلة عندما أريد تدريب مجموعة بيانات COCO. إليك كيفية إصلاح هذه المشكلة:

  1. أستخدم https://github.com/tylin/coco-dpm/blob/master/coco/convert_to_pascalformat.py لتحويل تنسيق COCO json إلى تنسيق XML.

  2. لكننا نحتاج إلى تعديل جزء من البرنامج النصي للتأكد من أن تنسيق ملف XML الجديد هذا هو نفس تنسيق VOC XML في مثال darkflow (darkflow / test / training / الشروح). فمثلا:
    COCO XML من نص الخطوة 1 هو:
    <tag1>
    xxxxx
    </tag1>
    <tag2>
    xxxxx
    </tag2>
    لكننا نحتاج إلى التنسيق مثل:
    <tag1>xxxxx</tag>
    <tag2>xxxxx</tag2>

3 قم بتغيير "tvmonitor" إلى "tv" في ملف "label.txt"

لقد حذفت جميع صور jpeg وعملت

مرحبا،

أنا أقوم بتدريب مجموعة بيانات جديدة. ومع ذلك ، يتم تشغيل التدريب دائمًا لبضع خطوات وفجأة يواجه الخطأ التالي: "AttributeError: كائن 'NoneType' ليس له سمة 'شكل'". أعتقد أن تنسيق التعليق التوضيحي واسم الملف في ملف التعليق التوضيحي صحيحان لأن التدريب قادر على العمل لبضع خطوات وأقوم بتشغيل الأفكار حول كيفية استكشاف المزيد من الأخطاء وإصلاحها.

نقدر أي أفكار أو تساعد في هذا.

شكرا لك.

root<strong i="10">@dd84391fd870</strong>:/ml/darkflow# flow --model cfg/tiny-yolo-new.cfg --train --dataset "../data/new/JPEGImages" --annotation "../data/new/Annotations"

Parsing cfg/tiny-yolo-new.cfg
Loading None ...
Finished in 0.00011324882507324219s

Building net ...
Source | Train? | Layer description                | Output size
-------+--------+----------------------------------+---------------
       |        | input                            | (?, 416, 416, 3)
 Init  |  Yep!  | conv 3x3p1_1  +bnorm  leaky      | (?, 416, 416, 16)
 Load  |  Yep!  | maxp 2x2p0_2                     | (?, 208, 208, 16)
 Init  |  Yep!  | conv 3x3p1_1  +bnorm  leaky      | (?, 208, 208, 32)
 Load  |  Yep!  | maxp 2x2p0_2                     | (?, 104, 104, 32)
 Init  |  Yep!  | conv 3x3p1_1  +bnorm  leaky      | (?, 104, 104, 64)
 Load  |  Yep!  | maxp 2x2p0_2                     | (?, 52, 52, 64)
 Init  |  Yep!  | conv 3x3p1_1  +bnorm  leaky      | (?, 52, 52, 128)
 Load  |  Yep!  | maxp 2x2p0_2                     | (?, 26, 26, 128)
 Init  |  Yep!  | conv 3x3p1_1  +bnorm  leaky      | (?, 26, 26, 256)
 Load  |  Yep!  | maxp 2x2p0_2                     | (?, 13, 13, 256)
 Init  |  Yep!  | conv 3x3p1_1  +bnorm  leaky      | (?, 13, 13, 512)
 Load  |  Yep!  | maxp 2x2p0_1                     | (?, 13, 13, 512)
 Init  |  Yep!  | conv 3x3p1_1  +bnorm  leaky      | (?, 13, 13, 1024)
 Init  |  Yep!  | conv 3x3p1_1  +bnorm  leaky      | (?, 13, 13, 1024)
 Init  |  Yep!  | conv 1x1p0_1    linear           | (?, 13, 13, 40)
-------+--------+----------------------------------+---------------
Running entirely on CPU
cfg/tiny-yolo-new.cfg loss hyper-parameters:
  H       = 13
  W       = 13
  box     = 5
  classes = 3
  scales  = [1.0, 5.0, 1.0, 1.0]
Building cfg/tiny-yolo-new.cfg loss
Building cfg/tiny-yolo-new.cfg train op
W tensorflow/core/platform/cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use SSE3 instructions, but these are available on your machine and could speed up CPU computations.
W tensorflow/core/platform/cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use SSE4.1 instructions, but these are available on your machine and could speed up CPU computations.
W tensorflow/core/platform/cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use SSE4.2 instructions, but these are available on your machine and could speed up CPU computations.
Finished in 7.207982778549194s

Enter training ...

cfg/tiny-yolo-new.cfg parsing ../data/new/Annotations
Parsing for ['tank', 'truck', 'apc'] 
[====================>]100%  000296.xml
Statistics:
apc: 48
tank: 70
truck: 24
Dataset size: 130
Dataset of 130 instance(s)
Training statistics: 
  Learning rate : 1e-05
  Batch size    : 16
  Epoch number  : 1000
  Backup every  : 2000
step 1 - loss 106.16172790527344 - moving ave loss 106.16172790527344
step 2 - loss 106.1773681640625 - moving ave loss 106.16329193115234
step 3 - loss 106.09341430664062 - moving ave loss 106.15630416870117
step 4 - loss 106.24054718017578 - moving ave loss 106.16472846984863
step 5 - loss 106.12216186523438 - moving ave loss 106.1604718093872
step 6 - loss 106.24075317382812 - moving ave loss 106.1684999458313
Traceback (most recent call last):
  File "/usr/local/bin/flow", line 6, in <module>
    cliHandler(sys.argv)
  File "/usr/local/lib/python3.5/dist-packages/darkflow/cli.py", line 29, in cliHandler
    print('Enter training ...'); tfnet.train()
  File "/usr/local/lib/python3.5/dist-packages/darkflow/net/flow.py", line 37, in train
    for i, (x_batch, datum) in enumerate(batches):
  File "/usr/local/lib/python3.5/dist-packages/darkflow/net/yolo/data.py", line 113, in shuffle
    inp, new_feed = self._batch(train_instance)
  File "/usr/local/lib/python3.5/dist-packages/darkflow/net/yolov2/data.py", line 27, in _batch
    img = self.preprocess(path, allobj)
  File "/usr/local/lib/python3.5/dist-packages/darkflow/net/yolo/predict.py", line 61, in preprocess
    result = imcv2_affine_trans(im)
  File "/usr/local/lib/python3.5/dist-packages/darkflow/utils/im_transform.py", line 19, in imcv2_affine_trans
    h, w, c = im.shape
AttributeError: 'NoneType' object has no attribute 'shape'

احذف جميع صور jpeg

مرحبًا ، أحاول تدريب اكتشاف الكائنات المخصصة لاكتشاف شعار شركتي ، وسار كل شيء على ما يرام حتى حدوث هذا الخطأ ، كما قمت بحذف الصور وإضافة تعليقات توضيحية إليها مرة أخرى ولكن لم يحدث أي تغيير في النتيجة. هل يمكن لأحد أن يساعدني في هذا
شكرا

(base) C:\Users\karanbari>cd Desktop/YOLO/darkflow-master

(base) C:\Users\karanbari\Desktop\YOLO\darkflow-master>python flow --model cfg/tiny-yolo-voc-1c.cfg --load bin/tiny-yolo-voc.weights --train --annotation annotations_clean --dataset images/train_clean --epoch 300
C:\Users\karanbari\Anaconda3\lib\site-packages\tensorflow\python\framework\dtypes.py:516: FutureWarning: Passing (type, 1) or '1type' as a synonym of type is deprecated; in a future version of numpy, it will be understood as (type, (1,)) / '(1,)type'.
  _np_qint8 = np.dtype([("qint8", np.int8, 1)])
C:\Users\karanbari\Anaconda3\lib\site-packages\tensorflow\python\framework\dtypes.py:517: FutureWarning: Passing (type, 1) or '1type' as a synonym of type is deprecated; in a future version of numpy, it will be understood as (type, (1,)) / '(1,)type'.
  _np_quint8 = np.dtype([("quint8", np.uint8, 1)])
C:\Users\karanbari\Anaconda3\lib\site-packages\tensorflow\python\framework\dtypes.py:518: FutureWarning: Passing (type, 1) or '1type' as a synonym of type is deprecated; in a future version of numpy, it will be understood as (type, (1,)) / '(1,)type'.
  _np_qint16 = np.dtype([("qint16", np.int16, 1)])
C:\Users\karanbari\Anaconda3\lib\site-packages\tensorflow\python\framework\dtypes.py:519: FutureWarning: Passing (type, 1) or '1type' as a synonym of type is deprecated; in a future version of numpy, it will be understood as (type, (1,)) / '(1,)type'.
  _np_quint16 = np.dtype([("quint16", np.uint16, 1)])
C:\Users\karanbari\Anaconda3\lib\site-packages\tensorflow\python\framework\dtypes.py:520: FutureWarning: Passing (type, 1) or '1type' as a synonym of type is deprecated; in a future version of numpy, it will be understood as (type, (1,)) / '(1,)type'.
  _np_qint32 = np.dtype([("qint32", np.int32, 1)])
C:\Users\karanbari\Anaconda3\lib\site-packages\tensorflow\python\framework\dtypes.py:525: FutureWarning: Passing (type, 1) or '1type' as a synonym of type is deprecated; in a future version of numpy, it will be understood as (type, (1,)) / '(1,)type'.
  np_resource = np.dtype([("resource", np.ubyte, 1)])
C:\Users\karanbari\Anaconda3\lib\site-packages\tensorboard\compat\tensorflow_stub\dtypes.py:541: FutureWarning: Passing (type, 1) or '1type' as a synonym of type is deprecated; in a future version of numpy, it will be understood as (type, (1,)) / '(1,)type'.
  _np_qint8 = np.dtype([("qint8", np.int8, 1)])
C:\Users\karanbari\Anaconda3\lib\site-packages\tensorboard\compat\tensorflow_stub\dtypes.py:542: FutureWarning: Passing (type, 1) or '1type' as a synonym of type is deprecated; in a future version of numpy, it will be understood as (type, (1,)) / '(1,)type'.
  _np_quint8 = np.dtype([("quint8", np.uint8, 1)])
C:\Users\karanbari\Anaconda3\lib\site-packages\tensorboard\compat\tensorflow_stub\dtypes.py:543: FutureWarning: Passing (type, 1) or '1type' as a synonym of type is deprecated; in a future version of numpy, it will be understood as (type, (1,)) / '(1,)type'.
  _np_qint16 = np.dtype([("qint16", np.int16, 1)])
C:\Users\karanbari\Anaconda3\lib\site-packages\tensorboard\compat\tensorflow_stub\dtypes.py:544: FutureWarning: Passing (type, 1) or '1type' as a synonym of type is deprecated; in a future version of numpy, it will be understood as (type, (1,)) / '(1,)type'.
  _np_quint16 = np.dtype([("quint16", np.uint16, 1)])
C:\Users\karanbari\Anaconda3\lib\site-packages\tensorboard\compat\tensorflow_stub\dtypes.py:545: FutureWarning: Passing (type, 1) or '1type' as a synonym of type is deprecated; in a future version of numpy, it will be understood as (type, (1,)) / '(1,)type'.
  _np_qint32 = np.dtype([("qint32", np.int32, 1)])
C:\Users\karanbari\Anaconda3\lib\site-packages\tensorboard\compat\tensorflow_stub\dtypes.py:550: FutureWarning: Passing (type, 1) or '1type' as a synonym of type is deprecated; in a future version of numpy, it will be understood as (type, (1,)) / '(1,)type'.
  np_resource = np.dtype([("resource", np.ubyte, 1)])
WARNING: Logging before flag parsing goes to stderr.
W1124 18:22:27.201594 10144 deprecation_wrapper.py:119] From C:\Users\karanbari\Desktop\YOLO\darkflow-master\darkflow\net\build.py:15: The name tf.train.RMSPropOptimizer is deprecated. Please use tf.compat.v1.train.RMSPropOptimizer instead.

W1124 18:22:27.209591 10144 deprecation_wrapper.py:119] From C:\Users\karanbari\Desktop\YOLO\darkflow-master\darkflow\net\build.py:16: The name tf.train.AdadeltaOptimizer is deprecated. Please use tf.compat.v1.train.AdadeltaOptimizer instead.

W1124 18:22:27.209591 10144 deprecation_wrapper.py:119] From C:\Users\karanbari\Desktop\YOLO\darkflow-master\darkflow\net\build.py:17: The name tf.train.AdagradOptimizer is deprecated. Please use tf.compat.v1.train.AdagradOptimizer instead.

W1124 18:22:27.213590 10144 deprecation_wrapper.py:119] From C:\Users\karanbari\Desktop\YOLO\darkflow-master\darkflow\net\build.py:18: The name tf.train.AdagradDAOptimizer is deprecated. Please use tf.compat.v1.train.AdagradDAOptimizer instead.

W1124 18:22:27.213590 10144 deprecation_wrapper.py:119] From C:\Users\karanbari\Desktop\YOLO\darkflow-master\darkflow\net\build.py:19: The name tf.train.MomentumOptimizer is deprecated. Please use tf.compat.v1.train.MomentumOptimizer instead.


Parsing ./cfg/tiny-yolo-voc.cfg
Parsing cfg/tiny-yolo-voc-1c.cfg
Loading bin/tiny-yolo-voc.weights ...
Successfully identified 63471556 bytes
Finished in 0.019990205764770508s

Building net ...
W1124 18:22:27.253580 10144 deprecation_wrapper.py:119] From C:\Users\karanbari\Desktop\YOLO\darkflow-master\darkflow\net\build.py:105: The name tf.placeholder is deprecated. Please use tf.compat.v1.placeholder instead.

Source | Train? | Layer description                | Output size
-------+--------+----------------------------------+---------------
W1124 18:22:27.257580 10144 deprecation_wrapper.py:119] From C:\Users\karanbari\Desktop\YOLO\darkflow-master\darkflow\net\ops\baseop.py:70: The name tf.variable_scope is deprecated. Please use tf.compat.v1.variable_scope instead.

W1124 18:22:27.261598 10144 deprecation_wrapper.py:119] From C:\Users\karanbari\Desktop\YOLO\darkflow-master\darkflow\net\ops\baseop.py:71: The name tf.get_variable is deprecated. Please use tf.compat.v1.get_variable instead.

W1124 18:22:27.277594 10144 deprecation_wrapper.py:119] From C:\Users\karanbari\Desktop\YOLO\darkflow-master\darkflow\net\ops\baseop.py:84: The name tf.placeholder_with_default is deprecated. Please use tf.compat.v1.placeholder_with_default instead.

       |        | input                            | (?, 416, 416, 3)
 Load  |  Yep!  | conv 3x3p1_1  +bnorm  leaky      | (?, 416, 416, 16)
W1124 18:22:27.389549 10144 deprecation_wrapper.py:119] From C:\Users\karanbari\Desktop\YOLO\darkflow-master\darkflow\net\ops\simple.py:106: The name tf.nn.max_pool is deprecated. Please use tf.nn.max_pool2d instead.

 Load  |  Yep!  | maxp 2x2p0_2                     | (?, 208, 208, 16)
 Load  |  Yep!  | conv 3x3p1_1  +bnorm  leaky      | (?, 208, 208, 32)
 Load  |  Yep!  | maxp 2x2p0_2                     | (?, 104, 104, 32)
 Load  |  Yep!  | conv 3x3p1_1  +bnorm  leaky      | (?, 104, 104, 64)
 Load  |  Yep!  | maxp 2x2p0_2                     | (?, 52, 52, 64)
 Load  |  Yep!  | conv 3x3p1_1  +bnorm  leaky      | (?, 52, 52, 128)
 Load  |  Yep!  | maxp 2x2p0_2                     | (?, 26, 26, 128)
 Load  |  Yep!  | conv 3x3p1_1  +bnorm  leaky      | (?, 26, 26, 256)
 Load  |  Yep!  | maxp 2x2p0_2                     | (?, 13, 13, 256)
 Load  |  Yep!  | conv 3x3p1_1  +bnorm  leaky      | (?, 13, 13, 512)
 Load  |  Yep!  | maxp 2x2p0_1                     | (?, 13, 13, 512)
 Load  |  Yep!  | conv 3x3p1_1  +bnorm  leaky      | (?, 13, 13, 1024)
 Load  |  Yep!  | conv 3x3p1_1  +bnorm  leaky      | (?, 13, 13, 1024)
 Init  |  Yep!  | conv 1x1p0_1    linear           | (?, 13, 13, 30)
-------+--------+----------------------------------+---------------
Running entirely on CPU
cfg/tiny-yolo-voc-1c.cfg loss hyper-parameters:
        H       = 13
        W       = 13
        box     = 5
        classes = 1
        scales  = [1.0, 5.0, 1.0, 1.0]
W1124 18:22:29.962576 10144 deprecation.py:323] From C:\Users\karanbari\Desktop\YOLO\darkflow-master\darkflow\net\yolov2\train.py:87: to_float (from tensorflow.python.ops.math_ops) is deprecated and will be removed in a future version.
Instructions for updating:
Use `tf.cast` instead.
Building cfg/tiny-yolo-voc-1c.cfg loss
W1124 18:22:30.010835 10144 deprecation_wrapper.py:119] From C:\Users\karanbari\Desktop\YOLO\darkflow-master\darkflow\net\yolov2\train.py:107: The name tf.summary.scalar is deprecated. Please use tf.compat.v1.summary.scalar instead.

Building cfg/tiny-yolo-voc-1c.cfg train op
W1124 18:22:30.102793 10144 deprecation.py:323] From C:\Users\karanbari\Anaconda3\lib\site-packages\tensorflow\python\ops\math_grad.py:1205: add_dispatch_support.<locals>.wrapper (from tensorflow.python.ops.array_ops) is deprecated and will be removed in a future version.
Instructions for updating:
Use tf.where in 2.0, which has the same broadcast rule as np.where
W1124 18:22:32.038406 10144 deprecation.py:506] From C:\Users\karanbari\Anaconda3\lib\site-packages\tensorflow\python\training\rmsprop.py:119: calling Ones.__init__ (from tensorflow.python.ops.init_ops) with dtype is deprecated and will be removed in a future version.
Instructions for updating:
Call initializer instance with the dtype argument instead of passing it to the constructor
W1124 18:22:32.795700 10144 deprecation_wrapper.py:119] From C:\Users\karanbari\Desktop\YOLO\darkflow-master\darkflow\net\build.py:145: The name tf.Session is deprecated. Please use tf.compat.v1.Session instead.

2019-11-24 18:22:32.800843: I tensorflow/core/platform/cpu_feature_guard.cc:142] Your CPU supports instructions that this TensorFlow binary was not compiled to use: AVX2
Finished in 11.774582862854004s

Enter training ...

cfg/tiny-yolo-voc-1c.cfg parsing annotations_clean
Parsing for ['vodafone']
[====================>]100%  Image9.xml
Statistics:
Dataset size: 53
Dataset of 53 instance(s)
Image20.jpg
Traceback (most recent call last):
  File "flow", line 6, in <module>
    cliHandler(sys.argv)
  File "C:\Users\karanbari\Desktop\YOLO\darkflow-master\darkflow\cli.py", line 33, in cliHandler
    print('Enter training ...'); tfnet.train()
  File "C:\Users\karanbari\Desktop\YOLO\darkflow-master\darkflow\net\flow.py", line 39, in train
    for i, (x_batch, datum) in enumerate(batches):
  File "C:\Users\karanbari\Desktop\YOLO\darkflow-master\darkflow\net\yolo\data.py", line 114, in shuffle
    inp, new_feed = self._batch(train_instance)
  File "C:\Users\karanbari\Desktop\YOLO\darkflow-master\darkflow\net\yolov2\data.py", line 28, in _batch
    img = self.preprocess(path, allobj)
  File "C:\Users\karanbari\Desktop\YOLO\darkflow-master\darkflow\net\yolo\predict.py", line 62, in preprocess
    result = imcv2_affine_trans(im)
  File "C:\Users\karanbari\Desktop\YOLO\darkflow-master\darkflow\utils\im_transform.py", line 20, in imcv2_affine_trans
    h, w, c = im.shape
AttributeError: 'NoneType' object has no attribute 'shape'

هل اسم صورتك له رموز خاصة؟ إذا كان الأمر كذلك ، قم بتغييرها.

في الأحد ، 24 نوفمبر 2019 الساعة 6:32 مساءً ، كتب karan bari [email protected] :

مرحبًا ، أحاول تدريب اكتشاف الكائنات المخصصة لاكتشاف ملفات
شعار الشركة ، سارت الأمور على ما يرام حتى هذا الخطأ ، لقد حذفت أيضًا و
الصور المشروحة مرة أخرى ولكن لا تغيير في النتيجة. هل يمكن لشخص ما من فضلك
ساعدني في ذلك
شكرا

(القاعدة) C: \ Users \ karanbari> cd Desktop / YOLO / darkflow-master

(القاعدة) C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-master> تدفق python --model cfg / tiny-yolo-voc-1c.cfg - تحميل bin / tiny-yolo-voc.weights - قطار - شرح annotations_clean - صور مجموعة البيانات / train_clean --epoch 300
C: \ Users \ karanbari \ Anaconda3 \ lib \ site -pack \ tensorflow \ python \ frameworkdtypes.py: 516: FutureWarning: التمرير (النوع ، 1) أو "1type" كمرادف للنوع تم إهماله ؛ في إصدار مستقبلي من numpy ، سيتم فهمه على أنه (type، (1،)) / '(1،) type'.
_np_qint8 = np.dtype ([("qint8"، np.int8، 1)])
C: \ Users \ karanbari \ Anaconda3 \ lib \ site -pack \ tensorflow \ python \ frameworkdtypes.py: 517: FutureWarning: التمرير (النوع ، 1) أو "1type" كمرادف للنوع تم إهماله ؛ في إصدار مستقبلي من numpy ، سيتم فهمه على أنه (type، (1،)) / '(1،) type'.
_np_quint8 = np.dtype ([("quint8"، np.uint8، 1)])
C: \ Users \ karanbari \ Anaconda3 \ lib \ site -pack \ tensorflow \ python \ frameworkdtypes.py: 518: FutureWarning: التمرير (النوع ، 1) أو "النوع 1" كمرادف للنوع تم إهماله ؛ في إصدار مستقبلي من numpy ، سيتم فهمه على أنه (type، (1،)) / '(1،) type'.
_np_qint16 = np.dtype ([("qint16"، np.int16، 1)])
C: \ Users \ karanbari \ Anaconda3 \ lib \ site -pack \ tensorflow \ python \ frameworkdtypes.py: 519: FutureWarning: التمرير (النوع ، 1) أو "1type" كمرادف للنوع تم إهماله ؛ في إصدار مستقبلي من numpy ، سيتم فهمه على أنه (type، (1،)) / '(1،) type'.
_np_quint16 = np.dtype ([("quint16"، np.uint16، 1)])
C: \ Users \ karanbari \ Anaconda3 \ lib \ site -pack \ tensorflow \ python \ frameworkdtypes.py: 520: FutureWarning: التمرير (النوع ، 1) أو "1type" كمرادف للنوع تم إهماله ؛ في إصدار مستقبلي من numpy ، سيتم فهمه على أنه (type، (1،)) / '(1،) type'.
_np_qint32 = np.dtype ([("qint32"، np.int32، 1)])
C: \ Users \ karanbari \ Anaconda3 \ lib \ site -pack \ tensorflow \ python \ frameworkdtypes.py: 525: FutureWarning: التمرير (النوع ، 1) أو "1type" كمرادف للنوع تم إهماله ؛ في إصدار مستقبلي من numpy ، سيتم فهمه على أنه (type، (1،)) / '(1،) type'.
np_resource = np.dtype ([("مورد"، np.ubyte، 1)])
C: \ Users \ karanbari \ Anaconda3 \ lib \ site -pack \ tensorboard \ موافقت \ tensorflow_stubdtypes.py: 541: FutureWarning: التمرير (النوع ، 1) أو "النوع 1" كمرادف للنوع تم إهماله ؛ في إصدار مستقبلي من numpy ، سيتم فهمه على أنه (type، (1،)) / '(1،) type'.
_np_qint8 = np.dtype ([("qint8"، np.int8، 1)])
C: \ Users \ karanbari \ Anaconda3 \ lib \ site -pack \ tensorboard \ موافقت \ tensorflow_stubdtypes.py: 542: FutureWarning: التمرير (النوع ، 1) أو "النوع 1" كمرادف للنوع تم إهماله ؛ في إصدار مستقبلي من numpy ، سيتم فهمه على أنه (type، (1،)) / '(1،) type'.
_np_quint8 = np.dtype ([("quint8"، np.uint8، 1)])
C: \ Users \ karanbari \ Anaconda3 \ lib \ site -pack \ tensorboard \ موافقت \ tensorflow_stubdtypes.py: 543: FutureWarning: التمرير (النوع ، 1) أو "النوع 1" كمرادف للنوع تم إهماله ؛ في إصدار مستقبلي من numpy ، سيتم فهمه على أنه (type، (1،)) / '(1،) type'.
_np_qint16 = np.dtype ([("qint16"، np.int16، 1)])
C: \ Users \ karanbari \ Anaconda3 \ lib \ site -pack \ tensorboard \ موافقت \ tensorflow_stubdtypes.py: 544: FutureWarning: التمرير (النوع ، 1) أو "النوع 1" كمرادف للنوع تم إهماله ؛ في إصدار مستقبلي من numpy ، سيتم فهمه على أنه (type، (1،)) / '(1،) type'.
_np_quint16 = np.dtype ([("quint16"، np.uint16، 1)])
C: \ Users \ karanbari \ Anaconda3 \ lib \ site -pack \ tensorboard \ موافقت \ tensorflow_stubdtypes.py: 545: FutureWarning: التمرير (النوع ، 1) أو "النوع 1" كمرادف للنوع تم إهماله ؛ في إصدار مستقبلي من numpy ، سيتم فهمه على أنه (type، (1،)) / '(1،) type'.
_np_qint32 = np.dtype ([("qint32"، np.int32، 1)])
C: \ Users \ karanbari \ Anaconda3 \ lib \ site -pack \ tensorboard \ مواف \ tensorflow_stubdtypes.py: 550: FutureWarning: التمرير (النوع ، 1) أو "النوع 1" كمرادف للنوع تم إهماله ؛ في إصدار مستقبلي من numpy ، سيتم فهمه على أنه (type، (1،)) / '(1،) type'.
np_resource = np.dtype ([("مورد"، np.ubyte، 1)])
تحذير: يذهب التسجيل قبل إعراب العلم إلى stderr.
W1124 18: 22: 27.201594 10144 devecation_wrapper.py:119] من C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ build.py: 15: الاسم tf.train.RMSPropOptimizer مهمل. الرجاء استخدام tf.compat.v1.train.RMSPropOptimizer بدلاً من ذلك.

W1124 18: 22: 27.209591 10144 devecation_wrapper.py:119] From C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ build.py: 16: الاسم tf.train.AdadeltaOptimizer مهمل. الرجاء استخدام tf.compat.v1.train.AdadeltaOptimizer بدلاً من ذلك.

W1124 18: 22: 27.209591 10144 devecation_wrapper.py:119] From C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ build.py: 17: الاسم tf.train.AdagradOptimizer مهمل. الرجاء استخدام tf.compat.v1.train.AdagradOptimizer بدلاً من ذلك.

W1124 18: 22: 27.213590 10144 devecation_wrapper.py:119] من C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ build.py: 18: الاسم tf.train.AdagradDAOptimizer مهمل. الرجاء استخدام tf.compat.v1.train.AdagradDAOptimizer بدلاً من ذلك.

W1124 18: 22: 27.213590 10144 devecation_wrapper.py:119] من C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ build.py: 19: تم إهمال الاسم tf.train.MomentumOptimizer. الرجاء استخدام tf.compat.v1.train.MomentumOptimizer بدلاً من ذلك.

الاعراب ./cfg/tiny-yolo-voc.cfg
تحليل cfg / tiny-yolo-voc-1c.cfg
تحميل صندوق / وزن صغير ...
تم التعرف بنجاح على 63471556 بايت
انتهى في 0.019990205764770508s

بناء شبكة ...
W1124 18: 22: 27.253580 10144 devecation_wrapper.py:119] From C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ build.py: 105: تم إهمال اسم tf.placeholder. الرجاء استخدام tf.compat.v1.placeholder بدلاً من ذلك.

المصدر | يدرب؟ | وصف الطبقة | حجم الإنتاج
------- + -------- + --------------------------------- - + ---------------
W1124 18: 22: 27.257580 10144 devecation_wrapper.py:119] From C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ ops \ baseop.py: 70: تم إهمال اسم tf.variable_scope. الرجاء استخدام tf.compat.v1.variable_scope بدلاً من ذلك.

W1124 18: 22: 27.261598 10144 devecation_wrapper.py:119] من C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ ops \ baseop.py: 71: تم إهمال الاسم tf.get_variable. الرجاء استخدام tf.compat.v1.get_variable بدلاً من ذلك.

W1124 18: 22: 27.277594 10144 devecation_wrapper.py:119] From C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ ops \ baseop.py: 84: تم إهمال الاسم tf.placeholder_with_default. الرجاء استخدام tf.compat.v1.placeholder_with_default بدلاً من ذلك.

   |        | input                            | (?, 416, 416, 3)

تحميل | نعم! | تحويل 3x3p1_1 + غير طبيعي تسرب | (؟، 416، 416، 16)
W1124 18: 22: 27.389549 10144 devecation_wrapper.py:119] من C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ ops \ simple.py: 106: تم إهمال الاسم tf.nn.max_pool. الرجاء استخدام tf.nn.max_pool2d بدلاً من ذلك.

تحميل | نعم! | maxp 2x2p0_2 | (؟ ، 208 ، 208 ، 16)
تحميل | نعم! | تحويل 3x3p1_1 + تسرب غير طبيعي | (؟ ، 208 ، 208 ، 32)
تحميل | نعم! | maxp 2x2p0_2 | (؟ ، 104 ، 104 ، 32)
تحميل | نعم! | تحويل 3x3p1_1 + تسرب غير طبيعي | (؟ ، 104 ، 104 ، 64)
تحميل | نعم! | maxp 2x2p0_2 | (؟ ، 52 ، 52 ، 64)
تحميل | نعم! | تحويل 3x3p1_1 + تسرب غير طبيعي | (؟ ، 52 ، 52 ، 128)
تحميل | نعم! | maxp 2x2p0_2 | (؟ ، 26 ، 26 ، 128)
تحميل | نعم! | تحويل 3x3p1_1 + تسرب غير طبيعي | (؟ ، 26 ، 26 ، 256)
تحميل | نعم! | maxp 2x2p0_2 | (؟ ، 13 ، 13 ، 256)
تحميل | نعم! | تحويل 3x3p1_1 + تسرب غير طبيعي | (؟، 13، 13، 512)
تحميل | نعم! | ماكس 2x2p0_1 | (؟، 13، 13، 512)
تحميل | نعم! | تحويل 3x3p1_1 + تسرب غير طبيعي | (؟، 13، 13، 1024)
تحميل | نعم! | تحويل 3x3p1_1 + غير طبيعي تسرب | (؟، 13، 13، 1024)
التهيئة | نعم! | تحويل 1x1p0_1 خطي | (؟ ، 13 ، 13 ، 30)
------- + -------- + --------------------------------- - + ---------------
يعمل بالكامل على وحدة المعالجة المركزية
cfg / tiny-yolo-voc-1c.cfg معلمات فرط الخسارة:
ع = 13
ث = 13
المربع = 5
الطبقات = 1
المقاييس = [1.0 ، 5.0 ، 1.0 ، 1.0]
W1124 18: 22: 29.962576 10144 premecation.py:323] From C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ yolov2 \ train.py: 87: to_float (from tensorflow.python.ops.math_ops) تم إهماله وستتم إزالتها في إصدار مستقبلي.
تعليمات التحديث:
استخدم tf.cast بدلاً من ذلك.
بناء cfg / خسارة صغيرة- yolo-voc-1c.cfg
W1124 18: 22: 30.010835 10144 devecation_wrapper.py:119] من C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ yolov2 \ train.py: 107: تم إهمال اسم tf.summary.scalar. الرجاء استخدام tf.compat.v1.summary.scalar بدلاً من ذلك.

بناء cfg / tiny-yolo-voc-1c.cfg قطار المرجع
W1124 18: 22: 30.102793 10144 devecation.py:323] من C: \ Users \ karanbari \ Anaconda3 \ lib \ site -packs \ tensorflow \ python \ ops \ math_grad.py: 1205: add_dispatch_support.تم إهمال .wrapper (من tensorflow.python.ops.array_ops) وستتم إزالته في إصدار مستقبلي.
تعليمات التحديث:
استخدم tf.where في الإصدار 2.0 ، والذي له نفس قاعدة البث مثل np.where
W1124 18: 22: 32.038406 10144 premecation.py:506] From C: \ Users \ karanbari \ Anaconda3 \ lib \ site -packs \ tensorflow \ python \ training \ rmsprop.py: 119: استدعاء Ones .__ init__ (من tensorflow.python .ops.init_ops) مع نوع dtype ، وستتم إزالته في إصدار مستقبلي.
تعليمات التحديث:
استدعاء مثيل مُهيئ باستخدام وسيطة dtype بدلاً من تمريرها إلى المُنشئ
W1124 18: 22: 32.795700 10144 devecation_wrapper.py:119] From C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ build.py: 145: اسم tf تم إهمال الجلسة. الرجاء استخدام tf.compat.v1.Session بدلاً من ذلك.

2019-11-24 18: 22: 32.800843: I tensorflow / core / platform / cpu_feature_guard.cc: 142] تدعم وحدة المعالجة المركزية الخاصة بك التعليمات التي تفيد بأن TensorFlow الثنائي لم يتم تجميعه للاستخدام: AVX2
انتهى في 11.774582862854004 ثانية

أدخل التدريب ...

cfg / tiny-yolo-voc-1c.cfg تحليل التعليقات التوضيحية_نظيفة
تحليل لـ ['vodafone']
[====================>] 100٪ Image9.xml
إحصائيات:
حجم مجموعة البيانات: 53
مجموعة بيانات من 53 مثيلًا (مثيلات)
Image20.jpg
Traceback (آخر مكالمة أخيرة):
ملف "تدفق" ، السطر 6 ، في
cliHandler (sys.argv)
ملف "C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ cli.py" ، السطر 33 ، في cliHandler
طباعة ("أدخل التدريب ...") ؛ tfnet.train ()
ملف "C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ flow.py" ، السطر 39 ، في القطار
بالنسبة إلى i ، (x_batch ، datum) في تعداد (دفعات):
ملف "C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ yolodata.py" ، السطر 114 ، بترتيب عشوائي
inp، new_feed = self._batch (train_instance)
ملف "C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ yolov2data.py" ، السطر 28 ، في _batch
img = self.preprocess (مسار ، allobj)
ملف "C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ yolo \ Forecast.py" ، السطر 62 ، في العملية التمهيدية
النتيجة = imcv2_affine_trans (im)
ملف "C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflowutils \ im_transform.py" ، السطر 20 ، في imcv2_affine_trans
ح ، ث ، ج = شكل ايم
AttributeError: الكائن "NoneType" ليس له سمة "شكل"

-
أنت تتلقى هذا لأنك علقت.
قم بالرد على هذا البريد الإلكتروني مباشرة ، وقم بعرضه على GitHub
https://github.com/thtrieu/darkflow/issues/265؟email_source=notifications&email_token=AGG23MNSSXWIHQFI75KYEWDQVJ3ORA5CNFSM4DNJVSV2YY3PNVWWK3TUL52HS4DFVREXG43VMVB38
أو إلغاء الاشتراك
https://github.com/notifications/unsubscribe-auth/AGG23MMETFBN5NG76IHGWZ3QVJ3ORANCNFSM4DNJVSVQ
.

هل اسم صورتك له رموز خاصة؟ إذا كان الأمر كذلك ، قم بتغييرها.
...
يوم الأحد، 24 نوفمبر 2019 الساعة 6:32 مساءً، karan bari @ . * > كتب: مرحبًا ، أحاول تدريب اكتشاف الكائنات المخصصة لاكتشاف شعار شركتي ، سارت الأمور على ما يرام حتى حدوث هذا الخطأ ، كما قمت بحذف الصور ووضع تعليقات توضيحية عليها مرة أخرى ولكن لم يحدث أي تغيير في النتيجة. هل يمكن لأي شخص مساعدتي في هذا شكرًا (القاعدة) C: \ Users \ karanbari> cd Desktop / YOLO / darkflow-master (قاعدة) C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-master> تدفق python --model cfg / tiny-yolo-voc-1c.cfg --load bin / tiny-yolo-voc.weights - القطار - التعليقات التوضيحية_clean - صور مجموعة البيانات / train_clean --epoch 300 C: \ Users \ karanbari \ Anaconda3 \ lib \ site -packages \ tensorflow \ python \ frameworkdtypes.py: 516: FutureWarning: التمرير (النوع ، 1) أو "النوع الأول" كمرادف للنوع تم إهماله ؛ في إصدار مستقبلي من numpy ، سيتم فهمه على أنه (type، (1،)) / '(1،) type'. _np_qint8 = np.dtype ([("qint8"، np.int8، 1)]) C: \ Users \ karanbari \ Anaconda3 \ lib \ site -pack \ tensorflow \ python \ frameworkdtypes.py: 517: FutureWarning: Passing (type ، 1) أو "1type" كمرادف للنوع مهمل ؛ في إصدار مستقبلي من numpy ، سيتم فهمه على أنه (type، (1،)) / '(1،) type'. _np_quint8 = np.dtype ([("quint8"، np.uint8، 1)]) C: \ Users \ karanbari \ Anaconda3 \ lib \ site -pack \ tensorflow \ python \ frameworkdtypes.py: 518: FutureWarning: Passing (type ، 1) أو "1type" كمرادف للنوع مهمل ؛ في إصدار مستقبلي من numpy ، سيتم فهمه على أنه (type، (1،)) / '(1،) type'. _np_qint16 = np.dtype ([("qint16"، np.int16، 1)]) C: \ Users \ karanbari \ Anaconda3 \ lib \ site -pack \ tensorflow \ python \ frameworkdtypes.py: 519: FutureWarning: Passing (type ، 1) أو "1type" كمرادف للنوع مهمل ؛ في إصدار مستقبلي من numpy ، سيتم فهمه على أنه (type، (1،)) / '(1،) type'. _np_quint16 = np.dtype ([("quint16"، np.uint16، 1)]) C: \ Users \ karanbari \ Anaconda3 \ lib \ site -pack \ tensorflow \ python \ frameworkdtypes.py: 520: FutureWarning: Passing (type ، 1) أو "1type" كمرادف للنوع مهمل ؛ في إصدار مستقبلي من numpy ، سيتم فهمه على أنه (type، (1،)) / '(1،) type'. _np_qint32 = np.dtype ([("qint32"، np.int32، 1)]) C: \ Users \ karanbari \ Anaconda3 \ lib \ site-packs \ tensorflow \ python \ frameworkdtypes.py: 525: FutureWarning: Passing (type ، 1) أو "1type" كمرادف للنوع مهمل ؛ في إصدار مستقبلي من numpy ، سيتم فهمه على أنه (type، (1،)) / '(1،) type'. np_resource = np.dtype ([("Resource"، np.ubyte، 1)]) C: \ Users \ karanbari \ Anaconda3 \ lib \ site -pack \ tensorboard \ implant \ tensorflow_stubdtypes.py: 541: FutureWarning: Passing (type ، 1) أو "1type" كمرادف للنوع مهمل ؛ في إصدار مستقبلي من numpy ، سيتم فهمه على أنه (type، (1،)) / '(1،) type'. _np_qint8 = np.dtype ([("qint8"، np.int8، 1)]) C: \ Users \ karanbari \ Anaconda3 \ lib \ site -pack \ tensorboard \ implant \ tensorflow_stubdtypes.py: 542: FutureWarning: Passing (type ، 1) أو "1type" كمرادف للنوع مهمل ؛ في إصدار مستقبلي من numpy ، سيتم فهمه على أنه (type، (1،)) / '(1،) type'. _np_quint8 = np.dtype ([("quint8"، np.uint8، 1)]) C: \ Users \ karanbari \ Anaconda3 \ lib \ site-packs \ tensorboard \ implant \ tensorflow_stubdtypes.py: 543: FutureWarning: Passing (type ، 1) أو "1type" كمرادف للنوع مهمل ؛ في إصدار مستقبلي من numpy ، سيتم فهمه على أنه (type، (1،)) / '(1،) type'. _np_qint16 = np.dtype ([("qint16"، np.int16، 1)]) C: \ Users \ karanbari \ Anaconda3 \ lib \ site -pack \ tensorboard \ implant \ tensorflow_stubdtypes.py: 544: FutureWarning: Passing (type ، 1) أو "1type" كمرادف للنوع مهمل ؛ في إصدار مستقبلي من numpy ، سيتم فهمه على أنه (type، (1،)) / '(1،) type'. _np_quint16 = np.dtype ([("quint16"، np.uint16، 1)]) C: \ Users \ karanbari \ Anaconda3 \ lib \ site-packs \ tensorboard \ implant \ tensorflow_stubdtypes.py: 545: FutureWarning: Passing (type ، 1) أو "1type" كمرادف للنوع مهمل ؛ في إصدار مستقبلي من numpy ، سيتم فهمه على أنه (type، (1،)) / '(1،) type'. _np_qint32 = np.dtype ([("qint32"، np.int32، 1)]) C: \ Users \ karanbari \ Anaconda3 \ lib \ site -pack \ tensorboard \ implant \ tensorflow_stubdtypes.py: 550: FutureWarning: Passing (type ، 1) أو "1type" كمرادف للنوع مهمل ؛ في إصدار مستقبلي من numpy ، سيتم فهمه على أنه (type، (1،)) / '(1،) type'. np_resource = np.dtype ([("Resource"، np.ubyte، 1)]) تحذير: التسجيل قبل تحليل العلم يذهب إلى stderr. W1124 18: 22: 27.201594 10144 devecation_wrapper.py:119] من C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ build.py: 15: الاسم tf.train.RMSPropOptimizer مهمل. الرجاء استخدام tf.compat.v1.train.RMSPropOptimizer بدلاً من ذلك. W1124 18: 22: 27.209591 10144 devecation_wrapper.py:119] From C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ build.py: 16: الاسم tf.train.AdadeltaOptimizer مهمل. الرجاء استخدام tf.compat.v1.train.AdadeltaOptimizer بدلاً من ذلك. W1124 18: 22: 27.209591 10144 devecation_wrapper.py:119] From C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ build.py: 17: الاسم tf.train.AdagradOptimizer مهمل. الرجاء استخدام tf.compat.v1.train.AdagradOptimizer بدلاً من ذلك. W1124 18: 22: 27.213590 10144 devecation_wrapper.py:119] من C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ build.py: 18: الاسم tf.train.AdagradDAOptimizer مهمل. الرجاء استخدام tf.compat.v1.train.AdagradDAOptimizer بدلاً من ذلك. W1124 18: 22: 27.213590 10144 devecation_wrapper.py:119] من C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ build.py: 19: تم إهمال الاسم tf.train.MomentumOptimizer. الرجاء استخدام tf.compat.v1.train.MomentumOptimizer بدلاً من ذلك. تحليل ./cfg/tiny-yolo-voc.cfg تحليل cfg / tiny-yolo-voc-1c.cfg تحميل bin / tiny-yolo-voc.weights ... تم تحديد 63471556 بايت بنجاح في 0.019990205764770508s بناء شبكة ... W1124 18: 22: 27.253580 10144 devecation_wrapper.py:119] From C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ build.py: 105: تم إهمال اسم tf.placeholder. الرجاء استخدام tf.compat.v1.placeholder بدلاً من ذلك. المصدر | يدرب؟ | وصف الطبقة | حجم الإخراج ------- + -------- + ------------------------------- --- + --------------- W1124 18: 22: 27.257580 10144 devecation_wrapper.py:119] من C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ ops \ baseop.py:70: اسم tf.variable_scope مهمل. الرجاء استخدام tf.compat.v1.variable_scope بدلاً من ذلك. W1124 18: 22: 27.261598 10144 devecation_wrapper.py:119] من C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ ops \ baseop.py: 71: تم إهمال الاسم tf.get_variable. الرجاء استخدام tf.compat.v1.get_variable بدلاً من ذلك. W1124 18: 22: 27.277594 10144 devecation_wrapper.py:119] From C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ ops \ baseop.py: 84: تم إهمال الاسم tf.placeholder_with_default. الرجاء استخدام tf.compat.v1.placeholder_with_default بدلاً من ذلك. | | الإدخال | (؟، 416، 416، 3) تحميل | نعم! | تحويل 3x3p1_1 + غير طبيعي تسرب | (؟، 416، 416، 16) W1124 18: 22: 27.389549 10144 devecation_wrapper.py:119] من C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ ops \ simple.py: 106: الاسم tf. تم إهمال nn.max_pool. الرجاء استخدام tf.nn.max_pool2d بدلاً من ذلك. تحميل | نعم! | maxp 2x2p0_2 | (؟، 208، 208، 16) تحميل | نعم! | تحويل 3x3p1_1 + غير طبيعي تسرب | (؟ ، 208 ، 208 ، 32) تحميل | نعم! | maxp 2x2p0_2 | (؟ ، 104 ، 104 ، 32) تحميل | نعم! | تحويل 3x3p1_1 + غير طبيعي تسرب | (؟، 104، 104، 64) تحميل | نعم! | maxp 2x2p0_2 | (؟ ، 52 ، 52 ، 64) تحميل | نعم! | تحويل 3x3p1_1 + غير طبيعي تسرب | (؟ ، 52 ، 52 ، 128) تحميل | نعم! | maxp 2x2p0_2 | (؟ ، 26 ، 26 ، 128) تحميل | نعم! | تحويل 3x3p1_1 + غير طبيعي تسرب | (؟ ، 26 ، 26 ، 256) تحميل | نعم! | maxp 2x2p0_2 | (؟ ، 13 ، 13 ، 256) تحميل | نعم! | تحويل 3x3p1_1 + غير طبيعي تسرب | (؟ ، 13 ، 13 ، 512) تحميل | نعم! | ماكس 2x2p0_1 | (؟ ، 13 ، 13 ، 512) تحميل | نعم! | تحويل 3x3p1_1 + غير طبيعي تسرب | (؟ ، 13 ، 13 ، 1024) تحميل | نعم! | تحويل 3x3p1_1 + غير طبيعي تسرب | (؟، 13، 13، 1024) التهيئة | نعم! | تحويل 1x1p0_1 خطي | (؟، 13، 13، 30) ------- + -------- + ------------------------ ---------- + --------------- يعمل بالكامل على وحدة المعالجة المركزية cfg / tiny-yolo-voc-1c.cfg معلمات الفقد الفائقة: H = 13 W = 13 مربع = 5 فئات = 1 مقياس = [1.0 ، 5.0 ، 1.0 ، 1.0] W1124 18: 22: 29.962576 10144 إهمال. py:323] من C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ yolov2 \ train.py:87: to_float (من tensorflow.python.ops.math_ops) مهمل وستتم إزالته في إصدار مستقبلي. إرشادات التحديث: استخدم tf.cast بدلاً من ذلك. بناء cfg / tiny-yolo-voc-1c.cfg loss W1124 18: 22: 30.010835 10144 premecation_wrapper.py:119] من C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ yolov2 \ train.py: 107: اسم tf.summary.scalar مهمل. الرجاء استخدام tf.compat.v1.summary.scalar بدلاً من ذلك. بناء cfg / tiny-yolo-voc-1c.cfg train op W1124 18: 22: 30.102793 10144 premecation.py:323] من C: \ Users \ karanbari \ Anaconda3 \ lib \ site -packs \ tensorflow \ python \ ops \ math_grad .py: 1205: add_dispatch_support.تم إهمال .wrapper (من tensorflow.python.ops.array_ops) وستتم إزالته في إصدار مستقبلي. إرشادات التحديث: استخدم tf.where في الإصدار 2.0 ، والذي له نفس قاعدة البث مثل np.where W1124 18: 22: 32.038406 10144 إهمال. py:506] من C: \ Users \ karanbari \ Anaconda3 \ lib \ site-pack \ تم إهمال tensorflow \ python \ training \ rmsprop.py: 119: استدعاء الآحاد .__ init__ (من tensorflow.python.ops.init_ops) بنوع dtype وستتم إزالتها في إصدار لاحق. إرشادات التحديث: مثيل مُهيئ الاستدعاء باستخدام وسيطة dtype بدلاً من تمريره إلى المُنشئ W1124 18: 22: 32.795700 10144 devecation_wrapper.py:119] من C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ build.py : 145: اسم tf.Session مهمل. الرجاء استخدام tf.compat.v1.Session بدلاً من ذلك. 2019-11-24 18: 22: 32.800843: I tensorflow / core / platform / cpu_feature_guard.cc: 142] تدعم وحدة المعالجة المركزية الخاصة بك التعليمات التي تفيد بأن هذا TensorFlow الثنائي لم يتم تجميعه للاستخدام: AVX2 انتهى في 11.774582862854004s أدخل التدريب ... cfg / tiny-yolo-voc-1c.cfg تحليل التعليقات التوضيحية_clean تحليل لـ ['vodafone'] [====================>] إحصائيات Image9.xml 100٪: حجم مجموعة البيانات : 53 مجموعة بيانات من 53 مثيلًا Image20.jpg Traceback (آخر مكالمة أخيرة): ملف "تدفق" ، سطر 6 ، فيcliHandler (sys.argv) ملف "C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ cli.py" ، السطر 33 ، في طباعة cliHandler ('أدخل التدريب ...') ؛ tfnet.train () ملف "C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ flow.py" ، السطر 39 ، في القطار لـ i ، (x_batch ، datum) في تعداد (دفعات): ملف "C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ yolodata.py "، السطر 114 ، في shuffle inp ، new_feed = self._batch (train_instance) ملف" C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ yolov2data.py "، السطر 28 ، في _batch img = self.preprocess (المسار ، allobj) ملف" C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ yolo \ Forecast.py "، السطر 62 ، في نتيجة المعالجة المسبقة = imcv2_affine_trans (im) ملف "C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflowutils \ im_transform.py" ، السطر 20 ، في imcv2_affine_trans h ، w ، c = im.shape AttributeError: شكل "NoneType" ليس له سمة " - أنت تتلقى هذا لأنك علقت. الرد على هذا البريد الإلكتروني مباشرة، مشاهدته على جيثب <# 265؟ email_source = الإخطارات وemail_token = AGG23MNSSXWIHQFI75KYEWDQVJ3ORA5CNFSM4DNJVSV2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEFAKXNA # issuecomment-557886388>، أو إلغاء الاشتراك https://github.com/notifications/unsubscribe-auth/AGG23MMETFBN5NG76IHGWZ3QVJ3ORANCNFSM4DNJVSVQ .

لا ، لقد أعدت إعادة تحميل جميع الصور بتنسيق Image1 و Image2 و Image3 ... إلخ وجميع الصور لها تنسيق jpg.

من المحتمل جدًا أن يكون أحد أبعاد التعليق التوضيحي أقل من
0 أو خارج الصورة.

تحقق أيضًا مما إذا كان يمكنك فتح جميع الصور يدويًا.

في يوم الأحد ، 24 نوفمبر 2019 الساعة 6:42 مساءً ، كتب karan bari [email protected] :

هل اسم صورتك له رموز خاصة؟ إذا كان الأمر كذلك ، قم بتغييرها.
… <# m_-6851739743886041955_>
يوم الأحد، 24 نوفمبر 2019 الساعة 6:32 مساءً، karan bari @ . * > كتب: مرحبًا أنا
محاولة تدريب اكتشاف العناصر المخصصة لاكتشاف شعار شركتي ،
سارت الأمور على ما يرام حتى هذا الخطأ ، قمت أيضًا بحذف الصور ووضع تعليقات توضيحية عليها
مرة أخرى ولكن لا تغيير في النتيجة. هل يمكن لأحد أن يساعدني في هذا
شكرًا لك (القاعدة) C: \ Users \ karanbari> cd Desktop / YOLO / darkflow-master (قاعدة)
C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-master> تدفق الثعبان - نموذج
cfg / tiny-yolo-voc-1c.cfg - تحميل بن / tiny-yolo-voc.weights - قطار
- التعليقات التوضيحية التوضيحية_نظيفة - صور مجموعة البيانات / train_clean - epoch 300
C: \ Users \ karanbari \ Anaconda3 \ lib \ site-packs \ tensorflow \ python \ frameworkdtypes.py: 516:
FutureWarning: التمرير (النوع ، 1) أو "النوع الأول" كمرادف للنوع هو
إهمال؛ في إصدار مستقبلي من numpy ، سيتم فهمه على أنه (type،
(1،)) / '(1،) اكتب'. _np_qint8 = np.dtype ([("qint8"، np.int8، 1)])
C: \ Users \ karanbari \ Anaconda3 \ lib \ site -packs \ tensorflow \ python \ frameworkdtypes.py: 517:
FutureWarning: التمرير (النوع ، 1) أو "النوع الأول" كمرادف للنوع هو
إهمال؛ في إصدار مستقبلي من numpy ، سيتم فهمه على أنه (type،
(1،)) / '(1،) اكتب'. _np_quint8 = np.dtype ([("quint8"، np.uint8، 1)])
C: \ Users \ karanbari \ Anaconda3 \ lib \ site -packs \ tensorflow \ python \ frameworkdtypes.py: 518:
FutureWarning: التمرير (النوع ، 1) أو "النوع الأول" كمرادف للنوع هو
إهمال؛ في إصدار مستقبلي من numpy ، سيتم فهمه على أنه (type،
(1،)) / '(1،) اكتب'. _np_qint16 = np.dtype ([("qint16"، np.int16، 1)])
C: \ Users \ karanbari \ Anaconda3 \ lib \ site -packs \ tensorflow \ python \ frameworkdtypes.py: 519:
FutureWarning: التمرير (النوع ، 1) أو "النوع الأول" كمرادف للنوع هو
إهمال؛ في إصدار مستقبلي من numpy ، سيتم فهمه على أنه (type،
(1،)) / '(1،) اكتب'. _np_quint16 = np.dtype ([("quint16"، np.uint16، 1)])
C: \ Users \ karanbari \ Anaconda3 \ lib \ site -packs \ tensorflow \ python \ frameworkdtypes.py: 520:
FutureWarning: التمرير (النوع ، 1) أو "النوع الأول" كمرادف للنوع هو
إهمال؛ في إصدار مستقبلي من numpy ، سيتم فهمه على أنه (type،
(1،)) / '(1،) اكتب'. _np_qint32 = np.dtype ([("qint32"، np.int32، 1)])
C: \ Users \ karanbari \ Anaconda3 \ lib \ site -packs \ tensorflow \ python \ frameworkdtypes.py: 525:
FutureWarning: التمرير (النوع ، 1) أو "النوع الأول" كمرادف للنوع هو
إهمال؛ في إصدار مستقبلي من numpy ، سيتم فهمه على أنه (type،
(1،)) / '(1،) اكتب'. np_resource = np.dtype ([("مورد"، np.ubyte، 1)])
C: \ Users \ karanbari \ Anaconda3 \ lib \ site-packs \ tensorboard \ Compatibility \ tensorflow_stubdtypes.py: 541:
FutureWarning: التمرير (النوع ، 1) أو "النوع الأول" كمرادف للنوع هو
إهمال؛ في إصدار مستقبلي من numpy ، سيتم فهمه على أنه (type،
(1،)) / '(1،) اكتب'. _np_qint8 = np.dtype ([("qint8"، np.int8، 1)])
C: \ Users \ karanbari \ Anaconda3 \ lib \ site-packs \ tensorboard \ Compatibility \ tensorflow_stubdtypes.py: 542:
FutureWarning: التمرير (النوع ، 1) أو "النوع الأول" كمرادف للنوع هو
إهمال؛ في إصدار مستقبلي من numpy ، سيتم فهمه على أنه (type،
(1،)) / '(1،) اكتب'. _np_quint8 = np.dtype ([("quint8"، np.uint8، 1)])
C: \ Users \ karanbari \ Anaconda3 \ lib \ site-packs \ tensorboard \ Compatibility \ tensorflow_stubdtypes.py: 543:
FutureWarning: التمرير (النوع ، 1) أو "النوع الأول" كمرادف للنوع هو
إهمال؛ في إصدار مستقبلي من numpy ، سيتم فهمه على أنه (type،
(1،)) / '(1،) اكتب'. _np_qint16 = np.dtype ([("qint16"، np.int16، 1)])
C: \ Users \ karanbari \ Anaconda3 \ lib \ site-packs \ tensorboard \ Compatibility \ tensorflow_stubdtypes.py: 544:
FutureWarning: التمرير (النوع ، 1) أو "النوع الأول" كمرادف للنوع هو
إهمال؛ في إصدار مستقبلي من numpy ، سيتم فهمه على أنه (type،
(1،)) / '(1،) اكتب'. _np_quint16 = np.dtype ([("quint16"، np.uint16، 1)])
C: \ Users \ karanbari \ Anaconda3 \ lib \ site-packs \ tensorboard \ Compatibility \ tensorflow_stubdtypes.py: 545:
FutureWarning: التمرير (النوع ، 1) أو "النوع الأول" كمرادف للنوع هو
إهمال؛ في إصدار مستقبلي من numpy ، سيتم فهمه على أنه (type،
(1،)) / '(1،) اكتب'. _np_qint32 = np.dtype ([("qint32"، np.int32، 1)])
C: \ Users \ karanbari \ Anaconda3 \ lib \ site-packs \ tensorboard \ Compatibility \ tensorflow_stubdtypes.py: 550:
FutureWarning: التمرير (النوع ، 1) أو "النوع الأول" كمرادف للنوع هو
إهمال؛ في إصدار مستقبلي من numpy ، سيتم فهمه على أنه (type،
(1،)) / '(1،) اكتب'. np_resource = np.dtype ([("مورد"، np.ubyte، 1)])
تحذير: يذهب التسجيل قبل إعراب العلم إلى stderr. W1124 18:22: 27.201594
10144 devecation_wrapper.py:119] من
C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ build.py: 15:
اسم tf.train.RMSPropOptimizer مهمل. من فضلك استخدم
بدلاً من ذلك ، يمكنك استخدام tf.compat.v1.train.RMSPropOptimizer. W1124 18:22: 27.209591 10144
devecation_wrapper.py:119] من
C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ build.py: 16:
اسم tf.train.AdadeltaOptimizer مهمل. من فضلك استخدم
tf.compat.v1.train.AdadeltaOptimizer بدلاً من ذلك. W1124 18:22: 27.209591 10144
devecation_wrapper.py:119] من
C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ build.py: 17:
اسم tf.train.AdagradOptimizer مهمل. من فضلك استخدم
tf.compat.v1.train.AdagradOptimizer بدلاً من ذلك. W1124 18:22: 27.213590 10144
devecation_wrapper.py:119] من
C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ build.py: 18:
اسم tf.train.AdagradDAOptimizer مهمل. من فضلك استخدم
tf.compat.v1.train.AdagradDAOptimizer بدلاً من ذلك. W1124 18:22: 27.213590 10144
devecation_wrapper.py:119] من
C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ build.py: 19:
تم إهمال الاسم tf.train.MomentumOptimizer. من فضلك استخدم
tf.compat.v1.train.MomentumOptimizer بدلاً من ذلك. تفسير
./cfg/tiny-yolo-voc.cfg تحليل cfg / tiny-yolo-voc-1c.cfg تحميل
bin / tiny-yolo-voc.weights ... تم تحديد 63471556 بايت بنجاح
انتهى في 0.019990205764770508s شبكة البناء ... W1124 18: 22: 27.253580
10144 devecation_wrapper.py:119] من
C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ build.py: 105:
تم إهمال اسم tf.placeholder. الرجاء استخدام tf.compat.v1.placeholder
في حين أن. المصدر | يدرب؟ | وصف الطبقة | حجم الإنتاج
------- + -------- + --------------------------------- - + --------------- W1124
18: 22: 27.257580 10144 devecation_wrapper.py:119] من
C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ ops \ baseop.py: 70:
اسم tf.variable_scope مهمل. من فضلك استخدم
بدلاً من ذلك ، يمكنك استخدام tf.compat.v1.variable_scope. W1124 18: 22: 27.261598 10144
devecation_wrapper.py:119] من
C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ ops \ baseop.py: 71:
اسم tf.get_variable مهمل. من فضلك استخدم
tf.compat.v1.get_variable بدلاً من ذلك. W1124 18: 22: 27.277594 10144
devecation_wrapper.py:119] من
C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ ops \ baseop.py: 84:
تم إهمال الاسم tf.placeholder_with_default. من فضلك استخدم
tf.compat.v1.placeholder_with_default بدلاً من ذلك. | | الإدخال | (؟، 416، 416، 3)
تحميل | نعم! | تحويل 3x3p1_1 + غير طبيعي تسرب | (؟، 416، 416، 16) W1124
18: 22: 27.389549 10144 devecation_wrapper.py:119] من
C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ ops \ simple.py: 106:
اسم tf.nn.max_pool مهمل. الرجاء استخدام tf.nn.max_pool2d بدلاً من ذلك.
تحميل | نعم! | maxp 2x2p0_2 | (؟، 208، 208، 16) تحميل | نعم! | تحويل 3x3p1_1
+ تسرب غير طبيعي | (؟ ، 208 ، 208 ، 32) تحميل | نعم! | maxp 2x2p0_2 | (؟ ، 104 ، 104 ،
32) تحميل | نعم! | تحويل 3x3p1_1 + غير طبيعي تسرب | (؟، 104، 104، 64) تحميل | نعم!
| maxp 2x2p0_2 | (؟ ، 52 ، 52 ، 64) تحميل | نعم! | تحويل 3x3p1_1 + غير طبيعي تسرب |
(؟ ، 52 ، 52 ، 128) تحميل | نعم! | maxp 2x2p0_2 | (؟ ، 26 ، 26 ، 128) تحميل | نعم!
| تحويل 3x3p1_1 + غير طبيعي تسرب | (؟ ، 26 ، 26 ، 256) تحميل | نعم! | maxp 2x2p0_2 |
(؟ ، 13 ، 13 ، 256) تحميل | نعم! | تحويل 3x3p1_1 + غير طبيعي تسرب | (؟، 13، 13، 512)
تحميل | نعم! | ماكس 2x2p0_1 | (؟ ، 13 ، 13 ، 512) تحميل | نعم! | تحويل 3x3p1_1
+ تسرب غير طبيعي | (؟ ، 13 ، 13 ، 1024) تحميل | نعم! | تحويل 3x3p1_1 + غير طبيعي تسرب |
(؟، 13، 13، 1024) التهيئة | نعم! | تحويل 1x1p0_1 خطي | (؟ ، 13 ، 13 ، 30)
------- + -------- + --------------------------------- - + --------------- الجري
بالكامل على وحدة المعالجة المركزية cfg / tiny-yolo-voc-1c.cfg المعلمات الفائقة للخسارة: H = 13 W =
13 صندوق = 5 فصول = مقياس واحد = [1.0 ، 5.0 ، 1.0 ، 1.0] W1124 18: 22: 29.962576
10144 depecation.py:323] من
C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ yolov2 \ train.py: 87:
to_float (من tensorflow.python.ops.math_ops) مهمل وسيتم
إزالتها في إصدار لاحق. تعليمات التحديث: استخدم tf.cast
في حين أن. بناء cfg / tiny-yolo-voc-1c.cfg خسارة W1124 18: 22: 30.010835 10144
devecation_wrapper.py:119] من
C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ yolov2 \ train.py: 107:
اسم tf.summary.scalar مهمل. من فضلك استخدم
tf.compat.v1.summary.scalar بدلاً من ذلك. بناء cfg / tiny-yolo-voc-1c.cfg
القطار المرجع W1124 18: 22: 30.102793 10144 الاستهلاك.py:323] من
C: \ Users \ karanbari \ Anaconda3 \ lib \ site -pack \ tensorflow \ python \ ops \ math_grad.py: 1205:
add_dispatch_support..wrapper (من tensorflow.python.ops.array_ops) هو
مهملة وستتم إزالتها في إصدار مستقبلي. تعليمات ل
التحديث: استخدم tf.where في الإصدار 2.0 ، والذي له نفس قاعدة البث مثل
np.where W1124 18: 22: 32.038406 10144 premecation.py:506] من
C: \ Users \ karanbari \ Anaconda3 \ lib \ site-packs \ tensorflow \ python \ training \ rmsprop.py: 119:
يدعو الآحاد. init (من tensorflow.python.ops.init_ops) مع dtype هو
مهملة وستتم إزالتها في إصدار مستقبلي. تعليمات ل
التحديث: مثيل مُهيئ الاستدعاء باستخدام وسيطة dtype بدلاً من
تمريره إلى المُنشئ W1124 18: 22: 32.795700 10144
devecation_wrapper.py:119] من
C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ build.py: 145:
تم تجاهل اسم tf.Session. الرجاء استخدام tf.compat.v1.Session بدلاً من ذلك.
24-11-2019 18:22: 32.800843: أنا
tensorflow / core / platform / cpu_feature_guard.cc: 142] تدعم وحدة المعالجة المركزية الخاصة بك
التعليمات التي لم يتم تجميع ملف TensorFlow الثنائي هذا لاستخدامه: AVX2
انتهى في 11.774582862854004s أدخل التدريب ... cfg / tiny-yolo-voc-1c.cfg
تحليل التعليقات التوضيحية_clean Parsing for ['vodafone']
[====================>] 100٪ Image9.xml الإحصائيات: حجم مجموعة البيانات: 53 مجموعة بيانات
من 53 مثيل (مثيلات) Image20.jpg التتبع (آخر مكالمة أخيرة): ملف
"التدفق" ، السطر 6 ، في ملف cliHandler (sys.argv)
"C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ cli.py" ، السطر 33 ،
في طباعة cliHandler ("أدخل التدريب ...") ؛ tfnet.train () ملف
"C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ flow.py"،
السطر 39 ، في القطار لـ i ، (x_batch ، datum) في تعداد (دفعات): ملف
"C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ yolodata.py" ،
سطر 114 ، في ملف inp عشوائي ، new_feed = self._batch (train_instance) ملف
"C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ yolov2data.py" ،
السطر 28 ، في ملف _batch img = self.preprocess (المسار ، allobj)
"C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflow \ net \ yolo \ Forecast.py"،
السطر 62 ، في نتيجة المعالجة المسبقة = ملف imcv2_affine_trans (im)
"C: \ Users \ karanbari \ Desktop \ YOLOdarkflow-masterdarkflowutils \ im_transform.py"،
السطر 20 ، في imcv2_affine_trans h، w، c = im.shape AttributeError:
كائن "NoneType" ليس له سمة "شكل" - أنت تتلقى هذا بسبب
قمت بالتعليق. قم بالرد على هذه الرسالة الإلكترونية مباشرة ، قم بعرضها على GitHub <# 265
https://github.com/thtrieu/darkflow/issues/265 ؟ email_source = الإخطارات والبريد الإلكتروني = AGG23MNSSXWIHQFI75KYEWDQVJ3ORA5CNFSM4DNJVSV2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63L ،
أو إلغاء الاشتراك
https://github.com/notifications/unsubscribe-auth/AGG23MMETFBN5NG76IHGWZ3QVJ3ORANCNFSM4DNJVSVQ
.

لا ، لقد أعدت إعادة تحميل جميع الصور بتنسيق Image1 و Image2 و Image3 ... إلخ
وجميع الصور لها تنسيق .jpg

-
أنت تتلقى هذا لأنك علقت.
قم بالرد على هذا البريد الإلكتروني مباشرة ، وقم بعرضه على GitHub
https://github.com/thtrieu/darkflow/issues/265؟
أو إلغاء الاشتراك
https://github.com/notifications/unsubscribe-auth/AGG23ML6HYW6S7JZEN2ZAF3QVJ4SVANCNFSM4DNJVSVQ
.

لقد قمت مرة أخرى بتعليق الصور هذه المرة باستخدام labelImg ، لا تزال المشكلة قائمة.

Enter training ...

cfg/tiny-yolo-voc-1c.cfg parsing annotations_clean
Parsing for ['vodafone']
[====================>]100%  Image8.xml
Statistics:
vodafone: 59
Dataset size: 51
Dataset of 51 instance(s)
**Image7.jpg**
Traceback (most recent call last):
  File "flow", line 6, in <module>
    cliHandler(sys.argv)
  File "C:\Users\karanbari\Desktop\YOLO\darkflow-master\darkflow\cli.py", line 33, in cliHandler
    print('Enter training ...'); tfnet.train()
  File "C:\Users\karanbari\Desktop\YOLO\darkflow-master\darkflow\net\flow.py", line 39, in train
    for i, (x_batch, datum) in enumerate(batches):
  File "C:\Users\karanbari\Desktop\YOLO\darkflow-master\darkflow\net\yolo\data.py", line 114, in shuffle
    inp, new_feed = self._batch(train_instance)
  File "C:\Users\karanbari\Desktop\YOLO\darkflow-master\darkflow\net\yolov2\data.py", line 28, in _batch
    img = self.preprocess(path, allobj)
  File "C:\Users\karanbari\Desktop\YOLO\darkflow-master\darkflow\net\yolo\predict.py", line 62, in preprocess
    result = imcv2_affine_trans(im)
  File "C:\Users\karanbari\Desktop\YOLO\darkflow-master\darkflow\utils\im_transform.py", line 20, in imcv2_affine_trans
    h, w, c = im.shape
AttributeError: 'NoneType' object has no attribute 'shape'

ها هو الخطأ مرة أخرى وملف .xml المقابل لـ Image7.jpg

<annotation>
    <folder>train_clean</folder>
    <filename>Image7.jpg</filename>
    <path>C:\Users\karanbari\Desktop\YOLO\images\train_clean\Image7.jpg</path>
    <source>
        <database>Unknown</database>
    </source>
    <size>
        <width>1300</width>
        <height>1390</height>
        <depth>3</depth>
    </size>
    <segmented>0</segmented>
    <object>
        <name>vodafone</name>
        <pose>Unspecified</pose>
        <truncated>0</truncated>
        <difficult>0</difficult>
        <bndbox>
            <xmin>370</xmin>
            <ymin>258</ymin>
            <xmax>916</xmax>
            <ymax>792</ymax>
        </bndbox>
    </object>
</annotation>

من الأفضل أن تضع
print(im, type(im))
في darkflow / net / yolo / Forecast.py في L58 وتحقق من المسار بنفسك

كان نفس الخطأ

كنت أواجه نفس المشكلة وكان إصلاحي:
تم تغيير im = cv2.imread (im) إلى im = cv2.imread (im + '. jpg') في سطر Forecast.py # 60

واجهت نفس المشكلة وكان ذلك لأنني قمت بحذف صورة jpg ولكني نسيت حذف التعليق التوضيحي الخاص بها. لذلك تأكد من أن الصور والتعليقات التوضيحية الخاصة بها متسقة.

هل كانت هذه الصفحة مفيدة؟
0 / 5 - 0 التقييمات