All Projects → gautam678 → Pix2depth

gautam678 / Pix2depth

Licence: gpl-3.0
DEPRECATED: Depth Map Estimation from Monocular Images

Programming Languages

python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to Pix2depth

Cyclegan
Software that can generate photos from paintings, turn horses into zebras, perform style transfer, and more.
Stars: ✭ 10,933 (+3631.4%)
Mutual labels:  gans, pix2pix, cyclegan
Pytorch Cyclegan And Pix2pix
Image-to-Image Translation in PyTorch
Stars: ✭ 16,477 (+5523.55%)
Mutual labels:  gans, pix2pix, cyclegan
Matlab Gan
MATLAB implementations of Generative Adversarial Networks -- from GAN to Pixel2Pixel, CycleGAN
Stars: ✭ 63 (-78.5%)
Mutual labels:  gans, pix2pix, cyclegan
Von
[NeurIPS 2018] Visual Object Networks: Image Generation with Disentangled 3D Representation.
Stars: ✭ 497 (+69.62%)
Mutual labels:  gans, pix2pix, cyclegan
pytorch-gans
PyTorch implementation of GANs (Generative Adversarial Networks). DCGAN, Pix2Pix, CycleGAN, SRGAN
Stars: ✭ 21 (-92.83%)
Mutual labels:  gans, pix2pix, cyclegan
Gan Compression
[CVPR 2020] GAN Compression: Efficient Architectures for Interactive Conditional GANs
Stars: ✭ 800 (+173.04%)
Mutual labels:  gans, pix2pix, cyclegan
Starnet
StarNet
Stars: ✭ 141 (-51.88%)
Mutual labels:  gans, pix2pix
Cyclegan
Tensorflow implementation of CycleGAN
Stars: ✭ 348 (+18.77%)
Mutual labels:  neural-networks, cyclegan
Cyclegan Qp
Official PyTorch implementation of "Artist Style Transfer Via Quadratic Potential"
Stars: ✭ 59 (-79.86%)
Mutual labels:  neural-networks, cyclegan
Deep Math Machine Learning.ai
A blog which talks about machine learning, deep learning algorithms and the Math. and Machine learning algorithms written from scratch.
Stars: ✭ 173 (-40.96%)
Mutual labels:  neural-networks, gans
Img2imggan
Implementation of the paper : "Toward Multimodal Image-to-Image Translation"
Stars: ✭ 49 (-83.28%)
Mutual labels:  gans, pix2pix
Torchgan
Research Framework for easy and efficient training of GANs based on Pytorch
Stars: ✭ 1,156 (+294.54%)
Mutual labels:  neural-networks, gans
Biggan Pytorch
The author's officially unofficial PyTorch BigGAN implementation.
Stars: ✭ 2,459 (+739.25%)
Mutual labels:  neural-networks, gans
Bicyclegan
Toward Multimodal Image-to-Image Translation
Stars: ✭ 1,215 (+314.68%)
Mutual labels:  gans, pix2pix
Hands On Deep Learning Algorithms With Python
Master Deep Learning Algorithms with Extensive Math by Implementing them using TensorFlow
Stars: ✭ 272 (-7.17%)
Mutual labels:  gans, cyclegan
coursera-gan-specialization
Programming assignments and quizzes from all courses within the GANs specialization offered by deeplearning.ai
Stars: ✭ 277 (-5.46%)
Mutual labels:  gans, pix2pix
Gan Mri
Code repository for Frontiers article 'Generative Adversarial Networks for Image-to-Image Translation on Multi-Contrast MR Images - A Comparison of CycleGAN and UNIT'
Stars: ✭ 159 (-45.73%)
Mutual labels:  neural-networks, cyclegan
traiNNer
traiNNer: Deep learning framework for image and video super-resolution, restoration and image-to-image translation, for training and testing.
Stars: ✭ 130 (-55.63%)
Mutual labels:  pix2pix, cyclegan
Contrastive Unpaired Translation
Contrastive unpaired image-to-image translation, faster and lighter training than cyclegan (ECCV 2020, in PyTorch)
Stars: ✭ 822 (+180.55%)
Mutual labels:  gans, cyclegan
Everybody-dance-now
Implementation of paper everybody dance now for Deep learning course project
Stars: ✭ 22 (-92.49%)
Mutual labels:  gans, pix2pix

No Maintenance Intended

Pix2Depth - Depth Map Estimation from Monocular Image

Update

I was not able to add the weights to the repository. I've created a drive and I'm adding the weights along with some images.

  • model - Weights from the experiment
  • src/model - Result of running the model on a sample image.

Weights and Results

Description

Estimating depth information from stereo images is easy, but does the same work for monocular images? We did all the heavylifting so you don't have to do it. We have explored several methods to extract depth from monocular images. Pix2Depth is a culmination of things we've learnt thus far.

Pix2Depth uses several strategies to extract depth from RGB images. Of all the strategies used, Pix2pix and CycleGAN give the best results. Pix2Depth is trained on the NYU Depth Dataset. Pix2Depth is also trained to predict RGB images from depth map.

The web demo for Pix2Depth can be found here

The web demo has three sections:

  • Pix2Depth - Using the models specified, give Pix2Depth an image and it will try to estimate the depth map.
  • Depth2Pix - From the Models given, Input a depth map and Pix2Depth will predict the estimated colour for the image.
  • Portrait Mode ( work in progress) - After obtaining the depth map, Pix2Depth uses the depth map to blur the background, so objects closer to the camera appear sharper while the background is blurred. This tries to emulate a potrait mode in smartphones without actually using stereo images.

Dataset

The dataset for this repo can be downloaded here.

Place the downloaded file in the folder data/

For the lazy: run download_nyu_dataset.sh to automatically download the dataset. Run save_all_images.py to store the images in seperate folders.

Required Packages

  • Keras
  • Flask
  • opencv
  • h5py
  • PIL
  • numpy

Running and evaluating

Configurations

CONFIG = {
        'development': False,
        'host': [host],
        'port': [port_number],
        'pix2depth':{
                'first_option':'pix2pix',
                'second_option':'CycleGAN',
                'third_option':'CNN',
        },
        'depth2pix':{
                'first_option':'pix2pix',
                'second_option':'CycleGAN',
                'third_option':'MSCNN'
        },
        'portrait':{
                'first_option': 'pix2pix',
                'second_option': 'CycleGAN',
                'third_option': 'CNN'
        }
}

Configure path to models

Loading the models stored in weights/ can be done inside main.py using model_list. This preloads all the models before inference hence saving a lot of time.

 model_list = {  
            'pix2depth':{ 
                'pix2pix' : load_model(),
                'CycleGAN':load_model(),
                'CNN': load_model(),
                },
            'depth2pix':{ 
                'pix2pix' : load_model(),
                'CycleGAN':load_model(),
                }
             }

Importing Models

Including Bootstrap Components

This demo requires Bootstrap (version 3). Bootstrap can be served to Flask from the static folder. The structure for storing the web-UI and images being displayed is as follows:

.
├── static
   ├── results
        └── results.jpg
        .
        .
        .
    └── uploads
        └── input.jpg
        .
        .
        .
   └── vendor
        └── bootstrap
                └── css
                └── js
        └── fonts
        └── jquery

Running the Application

python app.py

Examples

Output

  • main.py requires the path to the weights to load the model. The weights are stored in the folder weights/
  • The images are stored with the name of the model so it's easier to identify results. The generated images are stored in static/results/

Additional notes

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].