Skip to content

Commit

Permalink
Add smoothness flag to training script
Browse files Browse the repository at this point in the history
  • Loading branch information
oarriaga committed Dec 11, 2019
1 parent ae5005c commit 6f63440
Showing 1 changed file with 7 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
# os.environ["CUDA_DEVICE_ORDER"] = 'PCI_BUS_ID'
# os.environ["CUDA_VISIBLE_DEVICES"] = '0'
# os.environ["PYOPENGL_PLATFORM"] = 'egl'
from distutils.util import strtobool

import json
import argparse
Expand Down Expand Up @@ -57,6 +58,9 @@
parser.add_argument('-sh', '--sphere', default='full',
choices=['full', 'half'], type=str,
help='Flag for full sphere or top half for rendering')
parser.add_argument('-sm', '--smooth', type=strtobool, nargs='?',
const=True, default=True,
help='Activate smoothness trimesh flag for loading object')
parser.add_argument('-r', '--roll', default=3.14159, type=float,
help='Threshold for camera roll in radians')
parser.add_argument('-t', '--translation', default=None, type=float,
Expand All @@ -83,9 +87,11 @@


# setting scene
print('smoothness_flag', bool(args.smooth))
scene = MultiView(args.obj_path, (args.image_size, args.image_size),
args.y_fov, args.depth, args.sphere, args.roll,
args.translation, args.shift, args.light, args.background)
args.translation, args.shift, args.light,
args.background, bool(args.smooth))
focal_length = scene.camera.get_projection_matrix()[0, 0]

# setting sequencer
Expand Down

0 comments on commit 6f63440

Please sign in to comment.