Facemorphs - Images
Facemorphs / Baka Mitai Guide Image #2
![[2] cd first-order-model / content/first-order-model 3) Click this button 5) Click the link Mount your Google drive folder on Colab [3] from google.colab import drive drive.mount ('/content/gdrive') 4) Click this button Go to this URL in a browser: https://accounts.google.com/o/oauth2/auth?client_id=9473189{ Enter your authorization code: .......... Mounted at /content/gdrive Add folder https://drive.google.com/drive/folders/1kZ1gCnpfU0BnpdU47pLM _TQ6RypDDqgw? usp=sharing to your google drive.](https://i.kym-cdn.com/photos/images/masonry/001/880/148/98d.jpg)
![[2] cd first-order-model / content/first-order-model 3) Click this button 5) Click the link Mount your Google drive folder on Colab [3] from google.colab import drive drive.mount ('/content/gdrive') 4) Click this button Go to this URL in a browser: https://accounts.google.com/o/oauth2/auth?client_id=9473189{ Enter your authorization code: .......... Mounted at /content/gdrive Add folder https://drive.google.com/drive/folders/1kZ1gCnpfU0BnpdU47pLM _TQ6RypDDqgw? usp=sharing to your google drive.](https://i.kym-cdn.com/photos/images/original/001/880/148/98d.jpg)
Facemorphs
Facemorphs / Baka Mitai Guide Image #12


Facemorphs
Facemorphs / Baka Mitai Guide Image #11


Facemorphs
Facemorphs / Baka Mitai Guide Image #10
![+ Code + Text Copy to Drive E Files [22] from demo import load_checkpoints <> generator, kp_detector = load_checkpoints(config_path= checkpoint_path='/content/g first-order-model gdrive Perform image animation sample_data generated.mp4 make_animation ort img_as_ubyte Download Delete file ike_animation(source_image, driving_vide Rename file video Сoрy path 13) Right-click "generated.mp4, '../generated. mp4', [img_as_ubyte (frame Refresh wnloaded from /content folder then "download" HTML (display(source_image, driving_video, predictions).](https://i.kym-cdn.com/photos/images/masonry/001/880/043/e4a.jpg)
![+ Code + Text Copy to Drive E Files [22] from demo import load_checkpoints <> generator, kp_detector = load_checkpoints(config_path= checkpoint_path='/content/g first-order-model gdrive Perform image animation sample_data generated.mp4 make_animation ort img_as_ubyte Download Delete file ike_animation(source_image, driving_vide Rename file video Сoрy path 13) Right-click "generated.mp4, '../generated. mp4', [img_as_ubyte (frame Refresh wnloaded from /content folder then "download" HTML (display(source_image, driving_video, predictions).](https://i.kym-cdn.com/photos/images/original/001/880/043/e4a.jpg)
Facemorphs
Facemorphs / Baka Mitai Guide Image #9
![Ofirst-order-model-demo.ipynb File Edit View Insert Runtime Tools Help Cannot save changes + Code + Text A Copy to Drive Table of contents Demo for paper "First Order Motion Model for Image Animation" [22] from demo import load_checkpoints generator, kp_detector = load_checkpo checkpoin <> Running on your data B Section Perform image animation 12) Click this folder icon from demo import make_animation from skimage import img_as_ubyte predictions = make_animation(source_i #save resulting video imageio.mimsave('../generated.mp4', [ #video can be downloaded from /conten HTML (display(source_image, driving_vi 100%|| 836/836 [00:34<00:00](https://i.kym-cdn.com/photos/images/masonry/001/880/042/04e.jpg)
![Ofirst-order-model-demo.ipynb File Edit View Insert Runtime Tools Help Cannot save changes + Code + Text A Copy to Drive Table of contents Demo for paper "First Order Motion Model for Image Animation" [22] from demo import load_checkpoints generator, kp_detector = load_checkpo checkpoin <> Running on your data B Section Perform image animation 12) Click this folder icon from demo import make_animation from skimage import img_as_ubyte predictions = make_animation(source_i #save resulting video imageio.mimsave('../generated.mp4', [ #video can be downloaded from /conten HTML (display(source_image, driving_vi 100%|| 836/836 [00:34<00:00](https://i.kym-cdn.com/photos/images/original/001/880/042/04e.jpg)
Facemorphs
Facemorphs / Baka Mitai Guide Image #8
![Create a model and load checkpoints [5] from demo import load_checkpoints generator, kp_detector = load_checkpoints (config_path='config/vox-256.yaml', 10) Press this button checkpoint_path='/content/gdrive/My Drive/first-order-motion-model/vox-cpk. Perform image animation [6] from demo import make_animation from skimage import img_as_ubyte 11) Then this one predictions = make_animation(source_image, driving_video, generator, kp_detector, relative=True) #save resulting video imageio.mimsave('../generated.mp4', [img_as_ubyte(frame) for frame in predictions]) #video can be downloaded from /content folder HTML (display(source_image, driving_video, predictions).to_htm15_video()) 100%| || 211/211 [00:07<00:00, 29.03it/s]](https://i.kym-cdn.com/photos/images/masonry/001/880/041/b25.jpg)
![Create a model and load checkpoints [5] from demo import load_checkpoints generator, kp_detector = load_checkpoints (config_path='config/vox-256.yaml', 10) Press this button checkpoint_path='/content/gdrive/My Drive/first-order-motion-model/vox-cpk. Perform image animation [6] from demo import make_animation from skimage import img_as_ubyte 11) Then this one predictions = make_animation(source_image, driving_video, generator, kp_detector, relative=True) #save resulting video imageio.mimsave('../generated.mp4', [img_as_ubyte(frame) for frame in predictions]) #video can be downloaded from /content folder HTML (display(source_image, driving_video, predictions).to_htm15_video()) 100%| || 211/211 [00:07<00:00, 29.03it/s]](https://i.kym-cdn.com/photos/images/original/001/880/041/b25.jpg)
Facemorphs
Facemorphs / Baka Mitai Guide Image #7
![Load driving video and source image * V GD 0 i 7 import imageio import numpy as np import matplotlib.pyplot as plt import matplotlib.animation as animation 9) Press this button from skimage.transform import resize from IPython.display import HTML import warnings warnings.filterwarnings("ignore") source_image = imageio.imread('/content/gdrive/My Drive/first-order-motion-model/02.png') driving_video = imageio.mimread('/content/gdrive/My Drive/first-order-motion-model/04.mp4') #Resize image and video to 256x256 source_image = resize(source_image, (256, 256))[..., :3] driving_video = [resize(frame, (256, 256))[..., :3] for frame in driving_video] def display(source, driving, generated=None): fig = plt.figure (figsize=(8 + 4 * (generated is not None), 6)) ims = [] for i in range(len(driving)): cols = [source] cols.append (driving[i]) if generated is not None: cols.append(generated[i]) im = plt.imshow(np.concatenate(cols, axis=1), animated=True) plt.axis ('off') ims.append([im])](https://i.kym-cdn.com/photos/images/masonry/001/880/040/41f.jpg)
![Load driving video and source image * V GD 0 i 7 import imageio import numpy as np import matplotlib.pyplot as plt import matplotlib.animation as animation 9) Press this button from skimage.transform import resize from IPython.display import HTML import warnings warnings.filterwarnings("ignore") source_image = imageio.imread('/content/gdrive/My Drive/first-order-motion-model/02.png') driving_video = imageio.mimread('/content/gdrive/My Drive/first-order-motion-model/04.mp4') #Resize image and video to 256x256 source_image = resize(source_image, (256, 256))[..., :3] driving_video = [resize(frame, (256, 256))[..., :3] for frame in driving_video] def display(source, driving, generated=None): fig = plt.figure (figsize=(8 + 4 * (generated is not None), 6)) ims = [] for i in range(len(driving)): cols = [source] cols.append (driving[i]) if generated is not None: cols.append(generated[i]) im = plt.imshow(np.concatenate(cols, axis=1), animated=True) plt.axis ('off') ims.append([im])](https://i.kym-cdn.com/photos/images/original/001/880/040/41f.jpg)
Facemorphs
Facemorphs / Baka Mitai Guide Image #6


Facemorphs
Facemorphs / Baka Mitai Guide Image #5


Facemorphs
Facemorphs / Baka Mitai Guide Image #4


Facemorphs
Facemorphs / Baka Mitai Guide Image #3


Facemorphs
Facemorphs / Baka Mitai Guide Image #1
![Demo for paper "First Order Motion Model for Image Animation" 1) Paste this line Clone repository !pip install PYYAML==5.3.1 !git clone https://github.com/AliaksandrSiarohin/first-order-model Cloning into 'first-order-model'... remote: Enumerating objects: 85, done. remote: Total 85 (delta 0), reused e (delta 0), pack-reused 85 Unpacking objects: 100% (85/85), done. 2) Press this button [2] cd first-order-model A / content/first-order-model Mount your Google drive folder on Colab](https://i.kym-cdn.com/photos/images/masonry/001/880/032/a43.jpg)
![Demo for paper "First Order Motion Model for Image Animation" 1) Paste this line Clone repository !pip install PYYAML==5.3.1 !git clone https://github.com/AliaksandrSiarohin/first-order-model Cloning into 'first-order-model'... remote: Enumerating objects: 85, done. remote: Total 85 (delta 0), reused e (delta 0), pack-reused 85 Unpacking objects: 100% (85/85), done. 2) Press this button [2] cd first-order-model A / content/first-order-model Mount your Google drive folder on Colab](https://i.kym-cdn.com/photos/images/original/001/880/032/a43.jpg)
Facemorphs