GithubHelp home page GithubHelp logo

mortoupe69glorydoll / flowmap Goto Github PK

View Code? Open in Web Editor NEW

This project forked from dcharatan/flowmap

0.0 0.0 0.0 4.21 MB

Code for "FlowMap: High-Quality Camera Poses, Intrinsics, and Depth via Gradient Descent" by Cameron Smith*, David Charatan*, Ayush Tewari, and Vincent Sitzmann

Home Page: https://cameronosmith.github.io/flowmap/

License: MIT License

Shell 0.72% Python 99.28%

flowmap's Introduction

FlowMap

preview.mp4

This is the official implementation for FlowMap: High-Quality Camera Poses, Intrinsics, and Depth via Gradient Descent by Cameron Smith*, David Charatan*, Ayush Tewari, and Vincent Sitzmann.

Check out the project website here.

Installation

To get started on Linux, create a Python virtual environment:

python3.11 -m venv venv
source venv/bin/activate
pip install -r requirements.txt

For pretraining, make sure GMFlow is installed as a submodule:

git submodule update --init --recursive

If the above requirements don't work, you can try requirements_exact.txt instead.

Running the Code

The main entry point is flowmap/overfit.py. Call it via:

python3 -m flowmap.overfit dataset=images dataset.images.root=path/to/folder/with/images

Make sure the virtual environment has been activated via source venv/bin/activate first.

Pre-trained Initialization

The checkpoint we used to initialize FlowMap can be found here. To train your own, download the Real Estate 10k and CO3Dv2 datasets and run the following script:

python3 -m flowmap.pretrain

Some of the videos in the Real Estate 10k dataset are no longer publicly available. Reach out to us via email if you want our downloaded version of the dataset.

Evaluation Datasets

We evaluated FlowMap using video subsets of the Local Light Field Fusion (LLFF), Mip-NeRF 360, and Tanks & Temples datasets. We've uploaded a compilation of these datasets here.

Dataset Details

NeRF Local Light Field Fusion (LLFF) Scenes

These are the LLFF scenes from the NeRF paper, which were originally uploaded here. We used all 8 scenes (fern, flower, fortress, horns, leaves, orchids, room, and trex).

Mip-NeRF 360 Scenes

These are scenes from the Mip-NeRF 360 paper, which were originally uploaded here. We used the bonsai, counter, and kitchen scenes. The original kitchen scene consists of several concatenated video sequences; for FlowMap, we use the first one (65 frames). We also included the garden scene, which is somewhat video-like, but contain large jumps that make optical flow estimation struggle.

Tanks & Temples Scenes

We used all scenes from the Tanks & Temples dataset: auditorium, ballroom, barn, caterpillar, church, courthouse, family, francis, horse, ignatius, lighthouse, m60, meetingroom, museum, palace, panther, playground, temple, train, and truck. We preprocessed the raw videos from the dataset using the script at flowmap/subsample.py. This script samples 150 frames from the first minute of video evenly based on mean optical flow.

Running Ablations

Each ablation shown in the paper has a Hydra configuration at config/experiment. For example, to run the ablation where point tracking is disabled, add +experiment=ablation_no_tracks to the overfitting command. Note that you can stack most of the ablations, e.g., +experiment=[ablation_no_tracks,ablation_random_initialization].

Figure and Table Generation

Some of the code used to generate the tables and figures in the paper can be found in the assets folder.

BibTeX

@inproceedings{smith24flowmap,
      title={FlowMap: High-Quality Camera Poses, Intrinsics, and Depth via Gradient Descent},
      author={Cameron Smith and David Charatan and Ayush Tewari and Vincent Sitzmann},
      year={2024},
      booktitle={arXiv},
}

Acknowledgements

This work was supported by the National Science Foundation under Grant No. 2211259, by the Singapore DSTA under DST00OECI20300823 (New Representations for Vision), by the Intelligence Advanced Research Projects Activity (IARPA) via Department of Interior/ Interior Business Center (DOI/IBC) under 140D0423C0075, by the Amazon Science Hub, and by IBM. The Toyota Research Institute also partially supported this work. The views and conclusions contained herein reflect the opinions and conclusions of its authors and no other entity.

flowmap's People

Contributors

dcharatan avatar geyang avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.