{"id":18573555,"url":"https://github.com/prs-eth/implicity","last_synced_at":"2025-10-29T06:03:25.210Z","repository":{"id":46559093,"uuid":"461814653","full_name":"prs-eth/ImpliCity","owner":"prs-eth","description":"[ISPRS Congress 2022, Best Young Author Award] ImpliCity: City Modeling from Satellite Images with Deep Implicit Occupancy Fields","archived":false,"fork":false,"pushed_at":"2022-12-16T15:41:45.000Z","size":556,"stargazers_count":61,"open_issues_count":0,"forks_count":7,"subscribers_count":8,"default_branch":"main","last_synced_at":"2023-12-19T19:24:56.467Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/prs-eth.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2022-02-21T10:40:27.000Z","updated_at":"2023-12-09T15:38:01.000Z","dependencies_parsed_at":"2023-01-29T15:00:38.228Z","dependency_job_id":null,"html_url":"https://github.com/prs-eth/ImpliCity","commit_stats":null,"previous_names":[],"tags_count":0,"template":null,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/prs-eth%2FImpliCity","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/prs-eth%2FImpliCity/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/prs-eth%2FImpliCity/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/prs-eth%2FImpliCity/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/prs-eth","download_url":"https://codeload.github.com/prs-eth/ImpliCity/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":223430255,"owners_count":17143625,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-06T23:10:50.338Z","updated_at":"2025-10-29T06:03:20.174Z","avatar_url":"https://github.com/prs-eth.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# ImpliCity: City Modeling from Satellite Images with Deep Implicit Occupancy Fields\n\n![ImpliCity](docs/teaser.jpg?raw=true)\n\nThis repository provides the code to train and evaluate ImpliCity: a method that reconstructs digital surface models \n(DSMs) from raw photogrammetric 3D point clouds and ortho-images with the help of an implicit neural 3D scene representation.\nIt represents the official implementation of the paper:\n\n## [ImpliCity: City Modeling from Satellite Images with Deep Implicit Occupancy Fields](https://doi.org/10.5194/isprs-annals-V-2-2022-193-2022)\nCorinne Stucker, Bingxin Ke, Yuanwen Yue, Shengyu Huang, Iro Armeni, Konrad Schindler\n\n\u003e Abstract: *High-resolution optical satellite sensors, combined with dense stereo algorithms, have made it possible to reconstruct \n3D city models from space. However, these models are, in practice, rather noisy and tend to miss small geometric features that are \nclearly visible in the images. We argue that one reason for the limited quality may be a too early, heuristic reduction of the \ntriangulated 3D point cloud to an explicit height field or surface mesh. To make full use of the point cloud and the underlying images, \nwe introduce ImpliCity, a neural representation of the 3D scene as an implicit, continuous occupancy field, driven by learned embeddings \nof the point cloud and a stereo pair of ortho-photos. We show that this representation enables the extraction of high-quality DSMs: \nwith image resolution 0.5m, ImpliCity reaches a median height error of ≈0.7 m and outperforms competing methods, especially w.r.t. \nbuilding reconstruction, featuring intricate roof details, smooth surfaces, and straight, regular outlines.*\n\n[[supplementary]](https://arxiv.org/abs/2201.09968), [[video]](https://www.youtube.com/watch?v=7cheMxWhmjI)\n\n## Requirements\nThe code has been developed and tested with:\n* Ubuntu 20.04.4 LTS, Python 3.8.10, PyTorch 1.10.0, CUDA 10.2\n\n\n## Installation\n\n\nTo create a [Python virtual environment](https://docs.python.org/3/tutorial/venv.html) and install the required dependencies, please run:\n\n```bash\ngit clone git@github.com:prs-eth/ImpliCity.git\ncd ImpliCity\npython3 -m venv venv/implicity_env\nsource venv/implicity_env/bin/activate\n\npip3 install --upgrade pip setuptools wheel\npip3 install -r requirements.txt\n```\n\n**Manual installation of torch-scatter:**\n\nTo install the binaries for PyTorch 1.10.0, simply run:\n\n```bash\npip3 install torch-scatter -f https://data.pyg.org/whl/torch-1.10.0+${CUDA}.html\n```\nwhere `${CUDA}` should be replaced by either `cpu`, `cu102` (our environment), `cu111`, or `cu113`, depending on your PyTorch installation.\n\nFor other major OS/PyTorch/CUDA combinations, please refer to torch-scatter [official documentation](https://github.com/rusty1s/pytorch_scatter#pytorch-1100).\n\n\n## Usage\n### Training\nTo train ImpliCity from scratch, run:\n\n```bash\npython train.py \u003cpath/to/config.yaml\u003e\n```\n\nFor available training options, take a look at the example configuration files:\n* `./config/train_test/ImpliCity-0.yaml` for ImpliCity-0\n* `./config/train_test/ImpliCity-mono.yaml` for ImpliCity-mono\n* `./config/train_test/ImpliCity-stereo.yaml` for ImpliCity-stereo\n* `./config/train_test/train_base.yaml` for default settings\n\nThe configuration files are hierarchically inherited with new values or additional fields. `ImpliCity-0.yaml` and `ImpliCity-mono.yaml` are inherited from `train_base.yaml`,\nand `ImpliCity-stereo.yaml` is inherited from `ImpliCity-mono.yaml`.\n\n    \n### Evaluation\nTo evaluate a trained ImpliCity model, run:\n\n```bash\npython test.py \u003cpath/to/config.yaml\u003e\n```\n\nMake sure to include the path to the trained model weights in the configuration file `config.yaml`:\n\n```yaml\ntest:\n   check_point: \u003cpath/to/model/weights.pt\u003e\n```\n\n\n## Demo\n### Download demo\nWe provide a demo for a quick run-through:\n```\n./data/ImpliCity_demo\n├── data                        \n│   ├── chunk_000               # input point cloud and query points\n│   │   ├── ...\n│   │   └── vis                 # visualization of the demo training data\n│   │       └── ...\n│   └── raster                  # tiff files including cropped orthorectified images, masks, ground truth DSM\n│       └── ...\n│   \n├── expected_output             # expected output of different models (configurations) \n│   └── ...\n└── model                       # pretrained models\n    └── ...\n```\n\nPlease use this script to download our demo:\n```bash\nbash ./scripts/download_demo.sh\n```\n\nUnfortunately, we cannot share our complete dataset due to the commercial nature of VHR imagery. In this demo, we thus provide a small\npreprocessed demo dataset with a spatial extent of 64\u0026times;64 m in world coordinates:\n\n```yaml\n463948.875, 5249174.125; 464012.875, 5249238.125 (EPSG:32632 - WGS 84 / UTM zone 32N - Projected)\n```\n\n\n### Run demo\n\nTo run the pretrained model with demo data, please run:\n```bash\n# ImpliCity-0 demo:\npython test.py config/train_test/ImpliCity-0.yaml\n\n# ImpliCity-mono demo:\npython test.py config/train_test/ImpliCity-mono.yaml\n\n# ImpliCity-stereo demo:\npython test.py config/train_test/ImpliCity-stereo.yaml\n```\n\nTo continue training, please run:\n```bash\n# ImpliCity-0 demo:\npython train.py config/train_test/ImpliCity-0.yaml  --no-wandb\n\n# ImpliCity-mono demo:\npython train.py config/train_test/ImpliCity-mono.yaml  --no-wandb\n\n# ImpliCity-stereo demo:\npython train.py config/train_test/ImpliCity-stereo.yaml  --no-wandb\n```\n\n\n## Repository structure\n```\n.\n├── config                 \n│   ├── dataset            # configuration files for building the whole dataset\n│   │   └── ...\n│   └── train_test         # configuration files for training and inference \n│       └── ...             \n├── data                   # data and pretrained models\n├── out                    # output directory \n├── scripts                \n│   ├── dataset_ImpliCity/build_dataset.py   # python script to build the whole dataset (only for reference, would not work without all source data)\n│   └── download_demo.sh   # script to download demo data and pretrained models\n├── src                    \n│   └── ...                # source code of core modules\n├── LICENSE\n├── README.md              # this file\n├── requirements.txt       # dependency list\n├── test.py                # python script to test ImpliCity\n└── train.py               # python script to train ImpliCity\n```\n\n\n\n\n## Contact\nIf you run into any problems or have questions, please contact [Bingxin Ke](mailto:bingke@ethz.ch) and [Corinne Stucker](mailto:corinne.stucker@geod.baug.ethz.ch).\n\n\n## Citation\n\nIf you find our code or work useful, please cite:\n\n```bibtex\n@article{stucker2022implicity,\n    title={{ImpliCity}: City Modeling from Satellite Images with Deep Implicit Occupancy Fields},\n    author={Stucker, Corinne and Ke, Bingxin and Yue, Yuanwen and Huang, Shengyu and Armeni, Iro and Schindler, Konrad},\n    journal = {{ISPRS} Annals of the Photogrammetry, Remote Sensing and Spatial Information Sciences},\n    volume = {V-2-2022},\n    year = {2022},\n    pages = {193--201}\n}\n```\n\n## Acknowledgements\nIn this project we use (parts of) the official implementations of the following works:\n- [ConvONet](https://github.com/autonomousvision/convolutional_occupancy_networks)\n- [PIFu](https://github.com/shunsukesaito/PIFu)\n\nWe thank the respective authors for open sourcing and maintenance.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fprs-eth%2Fimplicity","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fprs-eth%2Fimplicity","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fprs-eth%2Fimplicity/lists"}