barvin04 / UprightNet_zhengqili

PyTorch implementation of paper "UprightNet: Geometry-Aware Camera Orientation Estimation from Single Images", ICCV 2019

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

UprightNet

PyTorch implementation of paper "UprightNet: Geometry-Aware Camera Orientation Estimation from Single Images", ICCV 2019 [Paper]

Dependency

The code is tested with Python3, Pytorch >= 1.0 and CUDA >= 10.0, the dependencies includes

  • tensorboardX
  • matplotlib
  • opencv
  • scikit-image
  • scipy

Dataset

  • Download pre-processed InteriorNet and ScanNet, as well as their corresponding training/validation/testing txt files from link
  • Modify the paths in train.py, test.py and txt files to match the dataset path in your machine.

Coordinate system

Our upright and local coordinate systems are defined as follows (corresponding to the normal images in the pre-processed datasets):

  • Z upward, Y right, X backward , equivalent to
  • Roll negative -> image rotate counterclockwise, Pitch positive -> camera rotate up

Training

  • To train the network on the InteriorNet, run
	python train.py --mode ResNet --dataset interiornet --w_grad 0.25 --w_pose 2.0
  • To train the network on the ScanNet, run
	python train.py --mode ResNet --dataset scannet --w_grad 0.25 --w_pose 0.5

Evaluation:

  • Download checkpoints.zip from link, unzip it and make sure checkpoints folder is in the root directory of codebase.

  • To evaluate InteriorNet pretrained network on the InteriorNet testset, run

	python test.py --mode ResNet --dataset interiornet
  • To evaluate ScanNet pretrained network on the ScanNet testset, run
	python test.py --mode ResNet --dataset scannet

About

PyTorch implementation of paper "UprightNet: Geometry-Aware Camera Orientation Estimation from Single Images", ICCV 2019

License:MIT License


Languages

Language:Python 100.0%