https://github.com/ChrisWu1997/2D-Motion-Retargeting
Tip revision: f3454a1972a98b3a572f83c1c9ea0b0e5d9e7d00 authored by Rundi Wu on 28 December 2020, 02:08:07 UTC
Update README.md
Update README.md
Tip revision: f3454a1
__init__.py
from model.networks import AutoEncoder2x, AutoEncoder3x
import torch.nn as nn
import torch.nn.functional as F
def get_autoencoder(config):
assert config.name is not None
if config.name == 'skeleton':
return AutoEncoder2x(config.mot_en_channels, config.body_en_channels, config.de_channels,
global_pool=F.max_pool1d, convpool=nn.MaxPool1d, compress=False)
elif config.name == 'view':
return AutoEncoder2x(config.mot_en_channels, config.view_en_channels, config.de_channels,
global_pool=F.max_pool1d, convpool=nn.MaxPool1d, compress=False) #FIXME: max/avg
else:
return AutoEncoder3x(config.mot_en_channels, config.body_en_channels,
config.view_en_channels, config.de_channels)
