{"id":13759957,"url":"https://github.com/lukasHoel/stylemesh","last_synced_at":"2025-05-10T10:31:19.458Z","repository":{"id":37623131,"uuid":"434550132","full_name":"lukasHoel/stylemesh","owner":"lukasHoel","description":"StyleMesh optimizes a stylized texture for an indoor scene reconstruction (CVPR2022).","archived":false,"fork":false,"pushed_at":"2023-07-16T10:18:21.000Z","size":102176,"stargazers_count":132,"open_issues_count":0,"forks_count":6,"subscribers_count":7,"default_branch":"master","last_synced_at":"2024-11-16T17:40:58.088Z","etag":null,"topics":["3d-reconstruction","style-transfer","stylemesh","styletransfer"],"latest_commit_sha":null,"homepage":"https://lukashoel.github.io/stylemesh/","language":"C++","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/lukasHoel.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,"governance":null,"roadmap":null,"authors":null}},"created_at":"2021-12-03T10:08:37.000Z","updated_at":"2024-08-29T11:41:18.000Z","dependencies_parsed_at":"2024-01-15T03:42:47.818Z","dependency_job_id":null,"html_url":"https://github.com/lukasHoel/stylemesh","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lukasHoel%2Fstylemesh","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lukasHoel%2Fstylemesh/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lukasHoel%2Fstylemesh/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lukasHoel%2Fstylemesh/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/lukasHoel","download_url":"https://codeload.github.com/lukasHoel/stylemesh/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253401117,"owners_count":21902607,"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":["3d-reconstruction","style-transfer","stylemesh","styletransfer"],"created_at":"2024-08-03T13:01:01.498Z","updated_at":"2025-05-10T10:31:14.450Z","avatar_url":"https://github.com/lukasHoel.png","language":"C++","funding_links":[],"categories":["C++"],"sub_categories":[],"readme":"# StyleMesh (CVPR2022)\n\nThis is the official repository that contains source code for the CVPR2022 paper [StyleMesh](https://lukashoel.github.io/stylemesh/).\n\n[[Arxiv](https://arxiv.org/abs/2112.01530)] [[Project Page](https://lukashoel.github.io/stylemesh/)] [[Video](https://www.youtube.com/watch?v=ZqgiTLcNcks)]\n\n![Teaser](static/images/teaser.jpg \"StyleMesh\")\n\nIf you find StyleMesh useful for your work please cite:\n```\n@inproceedings{hollein2022stylemesh,\n  title={StyleMesh: Style Transfer for Indoor 3D Scene Reconstructions},\n  author={H{\\\"o}llein, Lukas and Johnson, Justin and Nie{\\ss}ner, Matthias},\n  booktitle={Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition},\n  pages={6198--6208},\n  year={2022}\n}\n```\n\n## Preprocessing\nThe following steps are necessary to prepare all data.\n\n### Data Setup\n\n- Download Matterport and Scannet datasets (we use train scannet scenes only, see [scripts/scannet/scannet_train.txt](scripts/scannet/scannet_train.txt) for a complete list)\n- Prepare Scannet Scenes: see [scripts/scannet/prepare_data](scripts/scannet/prepare_data) and [scripts/scannet/filter/filter_blurry.py](scripts/scannet/filter/filter_blurry.py). This extracts RGB images and removes blurry frames.\n- Create texture parametrization for each mesh (requires blender): see [scripts/matterport/create_uvs.py](scripts/matterport/create_uvs.py) and [scripts/scannet/create_uvs.py](scripts/scannet/create_uvs.py). This saves a new version of each mesh file, that contains a uv texture parametrization. A sample output can be found here: https://drive.google.com/file/d/1x76zVka-Nkk87M0qZYwFZ51FUv6pVL8y/view?usp=sharing\n- Compile Matterport and Scannet renderers: see [scripts/matterport/render_uv](scripts/matterport/render_uv) and [scripts/scannet/render_uv](scripts/scannet/render_uv) for more details.\n- Render uv maps for Mattertport and Scannet: see [scripts/matterport/render_uvs.py](scripts/matterport/render_uvs.py) and [scripts/scannet/render_uvs.py](scripts/scannet/render_uvs.py). This preprocessing step speeds up the optimization by precomputing the texture lookups for each viewpoint. A sample output can be found here: https://drive.google.com/file/d/1QCOQivACD03ICIlO-E6ivEcfkDMuKYlM/view?usp=sharing\n\n### Project Setup\n- Download VGG Model: https://bethgelab.org/media/uploads/pytorch_models/vgg_conv.pth or https://drive.google.com/file/d/1IpTw7zOjWFMYXgt2zThPYIJ8c-DJw3xU/view?usp=sharing\n- Change dataset and vgg-model paths in [scripts/train/*](scripts/train) to your local machine locations\n- Create a conda environment and use it for all further executions: see [requirements.txt](requirements.txt)\n\n## Texture Optimization\nThe following steps allow to optimize a texture for a specific scene/style.\nYou can easily select scene/style by modifying the corresponding values in the scripts (--scene for ScanNet and additionally --region for Matterport).\nIt also allows to fine-tune loss weights, if you want to experiment with your own settings.\n\nAll style images that are used in the main paper are listed in [styles](styles).\n\nBy default, run files (texture, hparams, logging) are saved in [style-mesh/lightning_logs](lightning_logs)\n\n- Optimize Scannet: see [scripts/train/optimize_texture_scannet*.sh](scripts/train)\n- Optimize Matterport: see [scripts/train/optimize_texture_matterport*.sh](scripts/train)\n\nThe suffix \"with_angle_and_depth\" is used for comparisons in Fig. 4,5,6,7,8,9,11.\nThe suffixes \"only2D\" and \"with_angle\" are used for ablation study in Fig. 7.\nThe suffix \"dip\" is used for the DIP baseline in Fig. 4,5,6\n\n## Render optimized Texture\nYou can render images with Mipmapping and Shading with our OpenGL renderers for each dataset.\nAlternatively, you can use the generated texture files after each optimization together with the generated meshes\nand view the textured mesh in any mesh viewer (e.g. Meshlab or Blender).\n\n- Renderer Scannet: see [scripts/scannet/render_mipmap_scannet.py](scripts/scannet/render_mipmap_scannet.py)\n- Renderer Matterport: see [scripts/matterport/render_mipmap_matterport.py](scripts/matterport/render_mipmap_matterport.py)\n\n## Evaluate Reprojection Error\nWe use the file [scripts/eval/eval_image_folders.py](scripts/eval/eval_image_folders.py) for calculation of the reprojection error (Tab. 1)\n\n## Evaluate Circle Metric\nWe use the file [scripts/eval/measure_circles.py](scripts/eval/measure_circles.py) for calculation of the circle's metric (Tab. 2, Fig. 8)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FlukasHoel%2Fstylemesh","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FlukasHoel%2Fstylemesh","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FlukasHoel%2Fstylemesh/lists"}