After latest update Efficentnet(+V2) are not working

If training is failing to start, and you are not receiving an error message telling you what to do, tell us about it here


Forum rules

Read the FAQs and search the forum before posting a new topic.

This forum is for reporting errors with the Training process. If you want to get tips, or better understand the Training process, then you should look in the Training Discussion forum.

Please mark any answers that fixed your problems so others can find the solutions.

Locked
User avatar
Hanrahahanrahan
Posts: 8
Joined: Sat Aug 22, 2020 1:44 pm
Has thanked: 4 times
Been thanked: 1 time

After latest update Efficentnet(+V2) are not working

Post by Hanrahahanrahan »

Other models seemed fine, but current or new models created with any of the Efficentnet trainers exits with this error:

Code: Select all

08/23/2022 11:04:40 ERROR    Caught exception in thread: '_training_0'
08/23/2022 11:04:44 ERROR    Got Exception on main handler:
Traceback (most recent call last):
  File "T:\Deepfakes\_FaceswapBIN\faceswap\lib\cli\launcher.py", line 201, in execute_script
    process.process()
  File "T:\Deepfakes\_FaceswapBIN\faceswap\scripts\train.py", line 216, in process
    self._end_thread(thread, err)
  File "T:\Deepfakes\_FaceswapBIN\faceswap\scripts\train.py", line 256, in _end_thread
    thread.join()
  File "T:\Deepfakes\_FaceswapBIN\faceswap\lib\multithreading.py", line 121, in join
    raise thread.err[1].with_traceback(thread.err[2])
  File "T:\Deepfakes\_FaceswapBIN\faceswap\lib\multithreading.py", line 37, in run
    self._target(*self._args, **self._kwargs)
  File "T:\Deepfakes\_FaceswapBIN\faceswap\scripts\train.py", line 278, in _training
    raise err
  File "T:\Deepfakes\_FaceswapBIN\faceswap\scripts\train.py", line 268, in _training
    self._run_training_cycle(model, trainer)
  File "T:\Deepfakes\_FaceswapBIN\faceswap\scripts\train.py", line 353, in _run_training_cycle
    trainer.train_one_step(viewer, timelapse)
  File "T:\Deepfakes\_FaceswapBIN\faceswap\plugins\train\trainer\_base.py", line 244, in train_one_step
    self._update_viewers(viewer, timelapse_kwargs)
  File "T:\Deepfakes\_FaceswapBIN\faceswap\plugins\train\trainer\_base.py", line 343, in _update_viewers
    samples = self._samples.show_sample()
  File "T:\Deepfakes\_FaceswapBIN\faceswap\plugins\train\trainer\_base.py", line 643, in show_sample
    return self._compile_preview(preds)
  File "T:\Deepfakes\_FaceswapBIN\faceswap\plugins\train\trainer\_base.py", line 738, in _compile_preview
    display = self._to_full_frame(side, samples, preds)
  File "T:\Deepfakes\_FaceswapBIN\faceswap\plugins\train\trainer\_base.py", line 789, in _to_full_frame
    full = self._process_full(side, full, predictions[0].shape[1], (0, 0, 255))
  File "T:\Deepfakes\_FaceswapBIN\faceswap\plugins\train\trainer\_base.py", line 835, in _process_full
    cv2.rectangle(img, (t_l, t_l), (t_l + length, t_l + length), color, 1)
cv2.error: OpenCV(4.6.0) :-1: error: (-5:Bad argument) in function 'rectangle'
 Overload resolution failed:
  - Layout of the output array img is incompatible with cv::Mat
  - Expected Ptr<cv::UMat> for argument 'img'
  - Layout of the output array img is incompatible with cv::Mat
  - Expected Ptr<cv::UMat> for argument 'img'
User avatar
torzdf
Posts: 2649
Joined: Fri Jul 12, 2019 12:53 am
Answers: 159
Has thanked: 128 times
Been thanked: 623 times

Re: After latest update Efficentnet(+V2) are not working

Post by torzdf »

I pushed an update which should fix this yesterday. Please update.

If issue still persists, then please provide the full crash log.

My word is final

User avatar
Hanrahahanrahan
Posts: 8
Joined: Sat Aug 22, 2020 1:44 pm
Has thanked: 4 times
Been thanked: 1 time

Re: After latest update Efficentnet(+V2) are not working

Post by Hanrahahanrahan »

That was quick, it's on the latest version. Here's the crash report!

Attachments
crash_report.2022.08.23.111247410571.log
(39.68 KiB) Downloaded 88 times
User avatar
torzdf
Posts: 2649
Joined: Fri Jul 12, 2019 12:53 am
Answers: 159
Has thanked: 128 times
Been thanked: 623 times

Re: After latest update Efficentnet(+V2) are not working

Post by torzdf »

Uggh, that's my bad. I didn't push my local changes last night :roll_eyes:

Try now.

My word is final

User avatar
Hanrahahanrahan
Posts: 8
Joined: Sat Aug 22, 2020 1:44 pm
Has thanked: 4 times
Been thanked: 1 time

Re: After latest update Efficentnet(+V2) are not working

Post by Hanrahahanrahan »

Yeah works now, thanks mate!

Locked