📝 update README.md for better installation instructions

This commit is contained in:
Laurent FAINSIN 2023-05-30 11:46:06 +02:00
parent 377132fdd5
commit 43164f892f

View file

@ -6,9 +6,9 @@
This repository contains the implementation of the paper:
Shape As Points: A Differentiable Poisson Solver
[Songyou Peng](https://pengsongyou.github.io/), [Chiyu "Max" Jiang](https://www.maxjiang.ml/), [Yiyi Liao](https://yiyiliao.github.io/), [Michael Niemeyer](https://m-niemeyer.github.io/), [Marc Pollefeys](https://www.inf.ethz.ch/personal/pomarc/) and [Andreas Geiger](http://www.cvlibs.net/)
**NeurIPS 2021 (Oral)**
Shape As Points: A Differentiable Poisson Solver
[Songyou Peng](https://pengsongyou.github.io/), [Chiyu "Max" Jiang](https://www.maxjiang.ml/), [Yiyi Liao](https://yiyiliao.github.io/), [Michael Niemeyer](https://m-niemeyer.github.io/), [Marc Pollefeys](https://www.inf.ethz.ch/personal/pomarc/) and [Andreas Geiger](http://www.cvlibs.net/)
**NeurIPS 2021 (Oral)**
If you find our code or paper useful, please consider citing
@ -23,7 +23,7 @@ If you find our code or paper useful, please consider citing
## Installation
First you have to make sure that you have all dependencies in place.
The simplest way to do so, is to use [anaconda](https://www.anaconda.com/).
The simplest way to do so, is to use [anaconda](https://www.anaconda.com/).
You can create an anaconda environment called `sap` using
```
@ -31,14 +31,15 @@ conda env create -f environment.yaml
conda activate sap
```
Next, you should install [PyTorch3D](https://pytorch3d.org/) (**>=0.5**) yourself from the [official instruction](https://github.com/facebookresearch/pytorch3d/blob/master/INSTALL.md#3-install-wheels-for-linux).
Next, you should install [PyTorch3D](https://pytorch3d.org/) (**>=0.5**) yourself from the [official instruction](https://github.com/facebookresearch/pytorch3d/blob/master/INSTALL.md#3-install-wheels-for-linux).
And install [PyTorch Scatter](https://github.com/rusty1s/pytorch_scatter):
```sh
conda install pytorch-scatter -c pyg
```bash
git clone https://github.com/facebookresearch/pytorch3d.git
cd pytorch3d
module load compilers
pip install -e .
```
## Demo - Quick Start
First, run the script to get the demo data:
@ -82,7 +83,7 @@ You can find the reconstrution on `out/demo_shapenet_outlier/generation/vis`.
We have different dataset for our optimization-based and learning-based settings.
### Dataset for Optimization-based Reconstruction
Here we consider the following dataset:
Here we consider the following dataset:
- [Thingi10K](https://arxiv.org/abs/1605.04797) (synthetic)
- [Surface Reconstruction Benchmark (SRB)](https://github.com/fwilliams/deep-geometric-prior) (real scans)
- [MPI Dynamic FAUST](https://dfaust.is.tue.mpg.de/) (real scans)
@ -94,20 +95,20 @@ You can download the processed dataset (~200 MB) by running:
bash scripts/download_optim_data.sh
```
### Dataset for Learning-based Reconstruction
### Dataset for Learning-based Reconstruction
We train and evaluate on [ShapeNet](https://shapenet.org/).
You can download the processed dataset (~220 GB) by running:
```bash
bash scripts/download_shapenet.sh
```
```
After, you should have the dataset in `data/shapenet_psr` folder.
Alternatively, you can also preprocess the dataset yourself. To this end, you can:
Alternatively, you can also preprocess the dataset yourself. To this end, you can:
* first download the preprocessed dataset (73.4 GB) by running [the script](https://github.com/autonomousvision/occupancy_networks#preprocessed-data) from Occupancy Networks.
* check [`scripts/process_shapenet.py`](https://github.com/autonomousvision/shape_as_points/tree/main/scripts/process_shapenet.py), modify the base path and run the code
## Usage for Optimization-based 3D Reconstruction
## Usage for Optimization-based 3D Reconstruction
For our optimization-based setting, you can consider running with a coarse-to-fine strategy:
```python
@ -124,7 +125,7 @@ You might need to modify the `CONFIG.yaml` accordingly.
## Usage for Learning-based 3D Reconstruction
### Mesh Generation
### Mesh Generation
To generate meshes using a trained model, use
```python
python generate.py configs/learning_based/CONFIG.yaml