用Google colab 運行DeepFaceLab 詳細(xì)記錄

?https://drive.google.com/drive/?

https://github.com/dream80/DeepFaceLab_Colab.git












Running trainer.

Loading model...

Model first run. Enter model options as default for each run.

Write preview history? (y/n ?:help skip:n) : y

Target iteration (skip:unlimited/default) :

0

Batch_size (?:help skip:0) :

0

Feed faces to network sorted by yaw? (y/n ?:help skip:n) : y

Flip faces randomly? (y/n ?:help skip:y) : y

Src face scale modifier % ( -30...30, ?:help skip:0) :

0

Use lightweight autoencoder? (y/n, ?:help skip:n) : y

Use pixel loss? (y/n, ?:help skip: n/default ) : y

Using TensorFlow backend.

WARNING:tensorflow:From /usr/local/lib/python3.6/dist-packages/tensorflow/python/framework/op_def_library.py:263: colocate_with (from tensorflow.python.framework.ops) is deprecated and will be removed in a future version.

Instructions for updating:

Colocations handled automatically by placer.

Loading: 100% 654/654 [02:07<00:00,? 4.00it/s]

Sorting: 100% 64/64 [00:00<00:00, 4285.50it/s]

Loading: 100% 1523/1523 [05:12<00:00,? 6.61it/s]

Sorting: 100% 64/64 [00:00<00:00, 668.73it/s]

===== Model summary =====

== Model name: H128

==

== Current iteration: 0

==

== Model options:

== |== write_preview_history : True

== |== batch_size : 4

== |== sort_by_yaw : True

== |== random_flip : True

== |== lighter_ae : True

== |== pixel_loss : True

== Running on:

== |== [0 : Tesla T4]

=========================

Starting. Press "Enter" to stop training and save model.

WARNING:tensorflow:From /usr/local/lib/python3.6/dist-packages/tensorflow/python/ops/math_ops.py:3066: to_int32 (from tensorflow.python.ops.math_ops) is deprecated and will be removed in a future version.

Instructions for updating:

Use tf.cast instead.

[05:39:20][#003823][0208ms] loss_src:0.445 loss_dst:0.126

[05:54:20][#007671][0212ms] loss_src:0.613 loss_dst:0.136

[06:09:20][#011504][0210ms] loss_src:0.350 loss_dst:0.084

[06:24:21][#015315][0207ms] loss_src:0.287 loss_dst:0.065

[06:39:21][#019107][0206ms] loss_src:0.253 loss_dst:0.132

[06:54:21][#022889][0205ms] loss_src:0.447 loss_dst:0.065

[07:09:21][#026667][0206ms] loss_src:0.500 loss_dst:0.060

[07:24:21][#030449][0206ms] loss_src:0.223 loss_dst:0.071

[07:39:21][#034204][0205ms] loss_src:0.163 loss_dst:0.050

[07:54:21][#037950][0204ms] loss_src:0.355 loss_dst:0.060

[08:09:21][#041685][0205ms] loss_src:0.181 loss_dst:0.083

[08:24:21][#045403][0204ms] loss_src:0.228 loss_dst:0.068

[08:39:22][#049121][0208ms] loss_src:0.319 loss_dst:0.060

[08:54:22][#052831][0205ms] loss_src:0.188 loss_dst:0.036

[09:09:22][#056534][0206ms] loss_src:0.375 loss_dst:0.051

Enter

[09:24:01][#060135][0206ms] loss_src:0.270 loss_dst:0.076

[09:24:06][#060156][0211ms] loss_src:0.138 loss_dst:0.036

[09:24:22][#060221][0210ms] loss_src:0.427 loss_dst:0.098

[09:25:28][#060485][0207ms] loss_src:0.258 loss_dst:0.055

[09:25:31][#060498][0206ms] loss_src:0.150 loss_dst:0.042

[09:25:32][#060503][0206ms] loss_src:0.217 loss_dst:0.050

[09:25:32][#060504][0209ms] loss_src:0.135 loss_dst:0.051

[09:39:22][#063894][0206ms] loss_src:0.237 loss_dst:0.052

[09:54:22][#067565][0209ms] loss_src:0.172 loss_dst:0.041

[10:09:23][#071221][0202ms] loss_src:0.136 loss_dst:0.032

[10:24:23][#074871][0206ms] loss_src:0.167 loss_dst:0.089

[10:39:23][#078514][0203ms] loss_src:0.209 loss_dst:0.052

[10:54:23][#082151][0205ms] loss_src:0.191 loss_dst:0.059

[11:09:23][#085771][0209ms] loss_src:0.230 loss_dst:0.071

[11:24:23][#089392][0203ms] loss_src:0.268 loss_dst:0.050

[11:39:23][#092995][0208ms] loss_src:0.152 loss_dst:0.086

[11:54:23][#096591][0202ms] loss_src:0.145 loss_dst:0.051

[12:09:23][#100178][0209ms] loss_src:0.185 loss_dst:0.030

[12:10:20][#100400][0207ms] loss_src:0.128 loss_dst:0.045

[12:10:24][#100411][0209ms] loss_src:0.148 loss_dst:0.032

[12:10:24][#100412][0199ms] loss_src:0.121 loss_dst:0.052

11

[12:10:26][#100422][0202ms] loss_src:0.153 loss_dst:0.029

2

exit

[12:10:41][#100482][0205ms] loss_src:0.183 loss_dst:0.060

print(123)

Traceback (most recent call last):

? File "main.py", line 205, in <module>

? ? arguments.func(arguments)

? File "main.py", line 93, in process_train

? ? Trainer.main(args, device_args)

? File "/content/drive/My Drive/DeepFaceLab/DeepFaceLab_Colab/mainscripts/Trainer.py", line 150, in main

? ? io.process_messages(0.1)

? File "/content/drive/My Drive/DeepFaceLab/DeepFaceLab_Colab/interact/interact.py", line 118, in process_messages

? ? time.sleep(sleep_time)

KeyboardInterrupt

Process Process-3:

Process Process-4:

Process Process-1:

Process Process-2:

Traceback (most recent call last):

Traceback (most recent call last):

? File "/content/drive/My Drive/DeepFaceLab/DeepFaceLab_Colab/samples/SampleGeneratorFace.py", line 131, in batch_func

? ? x = SampleProcessor.process (sample, self.sample_process_options, self.output_sample_types, self.debug)

? File "/content/drive/My Drive/DeepFaceLab/DeepFaceLab_Colab/samples/SampleGeneratorFace.py", line 131, in batch_func

? ? x = SampleProcessor.process (sample, self.sample_process_options, self.output_sample_types, self.debug)

? File "/content/drive/My Drive/DeepFaceLab/DeepFaceLab_Colab/samples/SampleProcessor.py", line 169, in process

? ? img = cv2.warpAffine( img, LandmarksProcessor.get_transform_mat (sample.landmarks, size, target_face_type), (size,size), flags=cv2.INTER_CUBIC )

KeyboardInterrupt

During handling of the above exception, another exception occurred:

? File "/content/drive/My Drive/DeepFaceLab/DeepFaceLab_Colab/samples/SampleProcessor.py", line 169, in process

? ? img = cv2.warpAffine( img, LandmarksProcessor.get_transform_mat (sample.landmarks, size, target_face_type), (size,size), flags=cv2.INTER_CUBIC )

? File "/content/drive/My Drive/DeepFaceLab/DeepFaceLab_Colab/facelib/LandmarksProcessor.py", line 139, in get_transform_mat

? ? mat = umeyama(image_landmarks[17:], landmarks_2D, True)[0:2]

Traceback (most recent call last):

? File "/content/drive/My Drive/DeepFaceLab/DeepFaceLab_Colab/mathlib/umeyama.py", line 28, in umeyama

? ? src_mean = src.mean(axis=0)

? File "/usr/local/lib/python3.6/dist-packages/numpy/core/_methods.py", line 69, in _mean

? ? if issubclass(arr.dtype.type, (nt.integer, nt.bool_)):

KeyboardInterrupt

? File "/usr/lib/python3.6/multiprocessing/process.py", line 258, in _bootstrap

? ? self.run()

During handling of the above exception, another exception occurred:

Traceback (most recent call last):

? File "/usr/lib/python3.6/multiprocessing/process.py", line 93, in run

? ? self._target(*self._args, **self._kwargs)

? File "/usr/lib/python3.6/multiprocessing/process.py", line 258, in _bootstrap

? ? self.run()

? File "/content/drive/My Drive/DeepFaceLab/DeepFaceLab_Colab/utils/iter_utils.py", line 39, in process_func

? ? gen_data = next (self.generator_func)

? File "/content/drive/My Drive/DeepFaceLab/DeepFaceLab_Colab/samples/SampleGeneratorFace.py", line 133, in batch_func

? ? raise Exception ("Exception occured in sample %s. Error: %s" % (sample.filename, traceback.format_exc() ) )

Exception: Exception occured in sample /content/drive/My Drive/DeepFaceLab/workspace/data_dst/aligned/00487.jpg. Error: Traceback (most recent call last):

? File "/content/drive/My Drive/DeepFaceLab/DeepFaceLab_Colab/samples/SampleGeneratorFace.py", line 131, in batch_func

? ? x = SampleProcessor.process (sample, self.sample_process_options, self.output_sample_types, self.debug)

? File "/content/drive/My Drive/DeepFaceLab/DeepFaceLab_Colab/samples/SampleProcessor.py", line 169, in process

? ? img = cv2.warpAffine( img, LandmarksProcessor.get_transform_mat (sample.landmarks, size, target_face_type), (size,size), flags=cv2.INTER_CUBIC )

KeyboardInterrupt

? File "/usr/lib/python3.6/multiprocessing/process.py", line 93, in run

? ? self._target(*self._args, **self._kwargs)

? File "/content/drive/My Drive/DeepFaceLab/DeepFaceLab_Colab/utils/iter_utils.py", line 39, in process_func

? ? gen_data = next (self.generator_func)

? File "/content/drive/My Drive/DeepFaceLab/DeepFaceLab_Colab/samples/SampleGeneratorFace.py", line 133, in batch_func

? ? raise Exception ("Exception occured in sample %s. Error: %s" % (sample.filename, traceback.format_exc() ) )

Exception: Exception occured in sample /content/drive/My Drive/DeepFaceLab/workspace/data_src/aligned/00611.jpg. Error: Traceback (most recent call last):

? File "/content/drive/My Drive/DeepFaceLab/DeepFaceLab_Colab/samples/SampleGeneratorFace.py", line 131, in batch_func

? ? x = SampleProcessor.process (sample, self.sample_process_options, self.output_sample_types, self.debug)

? File "/content/drive/My Drive/DeepFaceLab/DeepFaceLab_Colab/samples/SampleProcessor.py", line 169, in process

? ? img = cv2.warpAffine( img, LandmarksProcessor.get_transform_mat (sample.landmarks, size, target_face_type), (size,size), flags=cv2.INTER_CUBIC )

? File "/content/drive/My Drive/DeepFaceLab/DeepFaceLab_Colab/facelib/LandmarksProcessor.py", line 139, in get_transform_mat

? ? mat = umeyama(image_landmarks[17:], landmarks_2D, True)[0:2]

? File "/content/drive/My Drive/DeepFaceLab/DeepFaceLab_Colab/mathlib/umeyama.py", line 28, in umeyama

? ? src_mean = src.mean(axis=0)

? File "/usr/local/lib/python3.6/dist-packages/numpy/core/_methods.py", line 69, in _mean

? ? if issubclass(arr.dtype.type, (nt.integer, nt.bool_)):

KeyboardInterrupt

Traceback (most recent call last):

? File "/usr/lib/python3.6/multiprocessing/process.py", line 258, in _bootstrap

? ? self.run()

? File "/usr/lib/python3.6/multiprocessing/process.py", line 93, in run

? ? self._target(*self._args, **self._kwargs)

? File "/content/drive/My Drive/DeepFaceLab/DeepFaceLab_Colab/utils/iter_utils.py", line 45, in process_func

? ? self.sc_queue.get()

? File "/usr/lib/python3.6/multiprocessing/queues.py", line 94, in get

? ? res = self._recv_bytes()

? File "/usr/lib/python3.6/multiprocessing/connection.py", line 216, in recv_bytes

? ? buf = self._recv_bytes(maxlength)

? File "/usr/lib/python3.6/multiprocessing/connection.py", line 407, in _recv_bytes

? ? buf = self._recv(4)

? File "/usr/lib/python3.6/multiprocessing/connection.py", line 379, in _recv

? ? chunk = read(handle, remaining)

KeyboardInterrupt

Traceback (most recent call last):

? File "/usr/lib/python3.6/multiprocessing/process.py", line 258, in _bootstrap

? ? self.run()

? File "/usr/lib/python3.6/multiprocessing/process.py", line 93, in run

? ? self._target(*self._args, **self._kwargs)

? File "/content/drive/My Drive/DeepFaceLab/DeepFaceLab_Colab/utils/iter_utils.py", line 45, in process_func

? ? self.sc_queue.get()

? File "/usr/lib/python3.6/multiprocessing/queues.py", line 94, in get

? ? res = self._recv_bytes()

? File "/usr/lib/python3.6/multiprocessing/connection.py", line 216, in recv_bytes

? ? buf = self._recv_bytes(maxlength)

? File "/usr/lib/python3.6/multiprocessing/connection.py", line 407, in _recv_bytes

? ? buf = self._recv(4)

? File "/usr/lib/python3.6/multiprocessing/connection.py", line 379, in _recv

? ? chunk = read(handle, remaining)

KeyboardInterrupt

/usr/lib/python3.6/multiprocessing/semaphore_tracker.py:143: UserWarning: semaphore_tracker: There appear to be 1 leaked semaphores to clean up at shutdown

? len(cache))

/usr/lib/python3.6/multiprocessing/semaphore_tracker.py:143: UserWarning: semaphore_tracker: There appear to be 1 leaked semaphores to clean up at shutdown

? len(cache))

/usr/lib/python3.6/multiprocessing/semaphore_tracker.py:143: UserWarning: semaphore_tracker: There appear to be 1 leaked semaphores to clean up at shutdown

? len(cache))

/usr/lib/python3.6/multiprocessing/semaphore_tracker.py:143: UserWarning: semaphore_tracker: There appear to be 1 leaked semaphores to clean up at shutdown

? len(cache))

Exception ignored in: <module 'threading' from '/usr/lib/python3.6/threading.py'>

Traceback (most recent call last):

? File "/usr/lib/python3.6/threading.py", line 1294, in _shutdown

/usr/lib/python3.6/multiprocessing/semaphore_tracker.py:143: UserWarning: semaphore_tracker: There appear to be 37 leaked semaphores to clean up at shutdown

? len(cache))

^C

#@title

# For preview, training must be stopped

# You can also view it in parallel with another .ipynb.?

#https://github.com/dream80/DeepFaceLab_Colab/blob/master/ViewLastHistory_H128.ipynb

import matplotlib.pyplot as plt

import tensorflow as tf

import numpy as np

import os

from google.colab import files

print(tf.__version__)

imgpath="/content/drive/My Drive/DeepFaceLab/workspace/model/H128_history/"

tlist=os.listdir(imgpath)

tlist.sort(key=lambda x:int(x[:-5]))

lastpic=tlist[-1]

image_raw = tf.gfile.GFile(imgpath+lastpic,'rb').read()? #bytes

img = tf.image.decode_jpeg(image_raw)? #Tensor

plt.rcParams['figure.figsize'] = (8, 4.0)

plt.rcParams['image.interpolation'] = 'nearest'

plt.rcParams['image.cmap'] = 'gray'

plt.rcParams['savefig.dpi'] =200

plt.rcParams['figure.dpi'] = 200

with tf.Session() as sess:

? ? plt.imshow(img.eval())





Collecting alignments: 100% 1523/1523 [00:03<00:00, 431.47it/s]

Running on CPU0.

Running on CPU1.

Converting:? 27% 413/1538 [05:33<15:08,? 1.24it/s]no faces found for 00954.png, copying without faces

Converting:? 33% 510/1538 [06:47<13:40,? 1.25it/s]no faces found for 01051.png, copying without faces

Converting:? 33% 511/1538 [06:47<13:38,? 1.25it/s]no faces found for 01052.png, copying without faces

Converting:? 34% 522/1538 [06:54<13:27,? 1.26it/s]no faces found for 01063.png, copying without faces

Converting:? 34% 524/1538 [06:55<13:23,? 1.26it/s]no faces found for 01064.png, copying without faces

no faces found for 01065.png, copying without faces

Converting:? 65% 998/1538 [13:15<07:10,? 1.25it/s]no faces found for 00001.png, copying without faces

Converting:? 65% 999/1538 [13:15<07:09,? 1.26it/s]no faces found for 00002.png, copying without faces

Converting:? 65% 1000/1538 [13:15<07:08,? 1.26it/s]no faces found for 00003.png, copying without faces

Converting:? 65% 1001/1538 [13:16<07:07,? 1.26it/s]no faces found for 00004.png, copying without faces

Converting:? 65% 1002/1538 [13:16<07:06,? 1.26it/s]no faces found for 00005.png, copying without faces

Converting:? 95% 1455/1538 [19:21<01:06,? 1.25it/s]no faces found for 00458.png, copying without faces

Converting:? 95% 1456/1538 [19:22<01:05,? 1.25it/s]no faces found for 00459.png, copying without faces

Converting:? 95% 1460/1538 [19:24<01:02,? 1.25it/s]no faces found for 00463.png, copying without faces

Converting:? 96% 1472/1538 [19:33<00:52,? 1.25it/s]no faces found for 00475.png, copying without faces

Converting: 100% 1538/1538 [20:24<00:00,? 1.26it/s]/usr/lib/python3.6/multiprocessing/semaphore_tracker.py:143: UserWarning: semaphore_tracker: There appear to be 1 leaked semaphores to clean up at shutdown

? len(cache))

/usr/lib/python3.6/multiprocessing/semaphore_tracker.py:143: UserWarning: semaphore_tracker: There appear to be 1 leaked semaphores to clean up at shutdown

? len(cache))

Converting: 100% 1538/1538 [20:24<00:00,? 1.26it/s]

Done.



然后打開?https://drive.google.com/drive/?查看結(jié)果





最后編輯于
?著作權(quán)歸作者所有,轉(zhuǎn)載或內(nèi)容合作請聯(lián)系作者
  • 序言:七十年代末绎秒,一起剝皮案震驚了整個濱河市,隨后出現(xiàn)的幾起案子,更是在濱河造成了極大的恐慌,老刑警劉巖文兑,帶你破解...
    沈念sama閱讀 212,718評論 6 492
  • 序言:濱河連續(xù)發(fā)生了三起死亡事件稍走,死亡現(xiàn)場離奇詭異哗总,居然都是意外死亡舔涎,警方通過查閱死者的電腦和手機(jī)誊役,發(fā)現(xiàn)死者居然都...
    沈念sama閱讀 90,683評論 3 385
  • 文/潘曉璐 我一進(jìn)店門,熙熙樓的掌柜王于貴愁眉苦臉地迎上來谷市,“玉大人蛔垢,你說我怎么就攤上這事∑扔疲” “怎么了鹏漆?”我有些...
    開封第一講書人閱讀 158,207評論 0 348
  • 文/不壞的土叔 我叫張陵,是天一觀的道長及皂。 經(jīng)常有香客問我甫男,道長,這世上最難降的妖魔是什么验烧? 我笑而不...
    開封第一講書人閱讀 56,755評論 1 284
  • 正文 為了忘掉前任,我火速辦了婚禮又跛,結(jié)果婚禮上碍拆,老公的妹妹穿的比我還像新娘。我一直安慰自己慨蓝,他們只是感情好感混,可當(dāng)我...
    茶點故事閱讀 65,862評論 6 386
  • 文/花漫 我一把揭開白布。 她就那樣靜靜地躺著礼烈,像睡著了一般弧满。 火紅的嫁衣襯著肌膚如雪。 梳的紋絲不亂的頭發(fā)上此熬,一...
    開封第一講書人閱讀 50,050評論 1 291
  • 那天庭呜,我揣著相機(jī)與錄音,去河邊找鬼犀忱。 笑死募谎,一個胖子當(dāng)著我的面吹牛,可吹牛的內(nèi)容都是我干的阴汇。 我是一名探鬼主播数冬,決...
    沈念sama閱讀 39,136評論 3 410
  • 文/蒼蘭香墨 我猛地睜開眼,長吁一口氣:“原來是場噩夢啊……” “哼搀庶!你這毒婦竟也來了拐纱?” 一聲冷哼從身側(cè)響起,我...
    開封第一講書人閱讀 37,882評論 0 268
  • 序言:老撾萬榮一對情侶失蹤哥倔,失蹤者是張志新(化名)和其女友劉穎秸架,沒想到半個月后,有當(dāng)?shù)厝嗽跇淞掷锇l(fā)現(xiàn)了一具尸體未斑,經(jīng)...
    沈念sama閱讀 44,330評論 1 303
  • 正文 獨居荒郊野嶺守林人離奇死亡咕宿,尸身上長有42處帶血的膿包…… 初始之章·張勛 以下內(nèi)容為張勛視角 年9月15日...
    茶點故事閱讀 36,651評論 2 327
  • 正文 我和宋清朗相戀三年币绩,在試婚紗的時候發(fā)現(xiàn)自己被綠了。 大學(xué)時的朋友給我發(fā)了我未婚夫和他白月光在一起吃飯的照片府阀。...
    茶點故事閱讀 38,789評論 1 341
  • 序言:一個原本活蹦亂跳的男人離奇死亡缆镣,死狀恐怖,靈堂內(nèi)的尸體忽然破棺而出试浙,到底是詐尸還是另有隱情董瞻,我是刑警寧澤,帶...
    沈念sama閱讀 34,477評論 4 333
  • 正文 年R本政府宣布田巴,位于F島的核電站钠糊,受9級特大地震影響,放射性物質(zhì)發(fā)生泄漏壹哺。R本人自食惡果不足惜抄伍,卻給世界環(huán)境...
    茶點故事閱讀 40,135評論 3 317
  • 文/蒙蒙 一、第九天 我趴在偏房一處隱蔽的房頂上張望管宵。 院中可真熱鬧截珍,春花似錦、人聲如沸箩朴。這莊子的主人今日做“春日...
    開封第一講書人閱讀 30,864評論 0 21
  • 文/蒼蘭香墨 我抬頭看了看天上的太陽炸庞。三九已至钱床,卻和暖如春,著一層夾襖步出監(jiān)牢的瞬間埠居,已是汗流浹背查牌。 一陣腳步聲響...
    開封第一講書人閱讀 32,099評論 1 267
  • 我被黑心中介騙來泰國打工, 沒想到剛下飛機(jī)就差點兒被人妖公主榨干…… 1. 我叫王不留拐格,地道東北人僧免。 一個月前我還...
    沈念sama閱讀 46,598評論 2 362
  • 正文 我出身青樓,卻偏偏與公主長得像捏浊,于是被迫代替她去往敵國和親懂衩。 傳聞我的和親對象是個殘疾皇子,可洞房花燭夜當(dāng)晚...
    茶點故事閱讀 43,697評論 2 351

推薦閱讀更多精彩內(nèi)容

  • rljs by sennchi Timeline of History Part One The Cognitiv...
    sennchi閱讀 7,312評論 0 10
  • 想從Tensorflow循環(huán)生成對抗網(wǎng)絡(luò)開始金踪。但是發(fā)現(xiàn)從最難的內(nèi)容入手還是浊洞?太復(fù)雜了所以搜索了一下他的始祖也就是深...
    Feather輕飛閱讀 5,038評論 1 4
  • ping error: Destination off-link but no route作者 codercjg ...
    codercjg閱讀 1,035評論 0 1
  • 學(xué)了一年多的舞蹈,小氣又吝嗇的我胡岔,居然把剛繳納了三個月學(xué)費的舞蹈課法希,說不上就不上了。 打敗我的不是外部多少惡劣的環(huán)...
    依依_c83d閱讀 147評論 0 0
  • 莫莫莫毛肋,錯錯錯,夢里方覺今非昨屋剑,但愿長醉不愿醒
    范馬奔騰的老爸閱讀 158評論 0 0