[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"project-83289":3},{"id":4,"name":5,"fullName":6,"owner":7,"repo":5,"description":8,"homepage":9,"htmlUrl":10,"language":11,"languages":10,"totalLinesOfCode":10,"stars":12,"forks":13,"watchers":14,"openIssues":15,"contributorsCount":15,"subscribersCount":15,"size":15,"stars1d":15,"stars7d":14,"stars30d":14,"stars90d":15,"forks30d":15,"starsTrendScore":15,"compositeScore":16,"rankGlobal":10,"rankLanguage":10,"license":17,"archived":18,"fork":18,"defaultBranch":19,"hasWiki":20,"hasPages":20,"topics":21,"createdAt":10,"pushedAt":10,"updatedAt":22,"readmeContent":23,"aiSummary":10,"trendingCount":15,"starSnapshotCount":15,"syncStatus":14,"lastSyncTime":24,"discoverSource":25},83289,"surge","karimknaebel\u002Fsurge","karimknaebel","SurGe: Improved Surface Geometry in Point Maps","https:\u002F\u002Fvision.rwth-aachen.de\u002Fsurge",null,"Python",54,1,2,0,42.1,"Other",false,"main",true,[],"2026-06-12 04:01:40","# 🌊 SurGe: Improved Surface Geometry in Point Maps\n\n[[`Paper`](https:\u002F\u002Fgithub.com\u002Fkarimknaebel\u002Fstorage\u002Freleases\u002Fdownload\u002Fsurge-assets\u002Fsurge-v1.pdf)] [[`arXiv`](https:\u002F\u002Farxiv.org\u002Fabs\u002F2605.31577)] [[`Project Page`](http:\u002F\u002Fvision.rwth-aachen.de\u002Fsurge)] [[`Weights`](https:\u002F\u002Fhuggingface.co\u002Fkarimknaebel\u002Fsurge-large\u002Ftree\u002Fmain)] [[`Demo`](https:\u002F\u002Fhuggingface.co\u002Fspaces\u002Fkarimknaebel\u002Fsurge)] [[`BibTeX`](#-Citation)]\n\n\u003Ctable>\u003Ctr>\u003Ctd>\u003Cimg width=\"2491\" height=\"1291\" alt=\"architecture\" src=\"https:\u002F\u002Fgithub.com\u002Fuser-attachments\u002Fassets\u002Faab62446-15ec-478a-92ba-d9fd1c117812\" \u002F>\u003C\u002Ftd>\u003C\u002Ftr>\u003C\u002Ftable>\n\n## 📢 News\n\n- 2026-06-01: arXiv v1, inference code, weights and demo.\n\n## Installation\n\n```\nuv sync --extra cli --extra app\n```\n\n## Usage\n\n### Python API\n\nSurGe expects image tensors in `BCHW` format with unnormalized RGB values in `[0, 1]`.\nDo not apply ImageNet normalization or similar preprocessing.\n\n> [!TIP]\nIf you want the exact model from the arXiv v1 paper, you can `git checkout v1` and specify corresponding checkpoint version `SurGe.from_pretrained(\"karimknaebel\u002Fsurge-large\", revision=\"v1\")`.\n\n```python\nimport torch\nfrom surge import SurGe\n\nmodel = SurGe.from_pretrained(\"karimknaebel\u002Fsurge-large\").eval().cuda()\nimage = torch.rand(1, 3, 518, 518, device=\"cuda\")\n\nresult = model.infer(image, num_tokens=\"max\")\npoints = result[\"points\"]          # (B, H, W, 3)\ndepth = result[\"depth\"]            # (B, H, W)\nintrinsics = result[\"intrinsics\"]  # (B, 3, 3)\n```\n\n`num_tokens` controls the encoder token budget.\nUse `\"min\"`, `\"max\"`, or an integer value.\n\n### CLI\n\nRun inference on an image or a directory of images:\n\n```\nuv run --extra cli surge-cli path\u002Fto\u002Fimage.jpg --output-dir output\n```\n\nBy default, the CLI writes `mesh.glb` for each input image.\nAdd output flags as needed:\n\n```\nuv run --extra cli surge-cli path\u002Fto\u002Fimages --save-maps --save-glb --save-ply\n```\n\nUseful options include `--max-size 1200`, `--tokens max`, `--fov-x 60`, `--fp16`, and `--filter-sky`.\nFor interactive viewing, use `--show-mesh` to open the reconstructed mesh with trimesh, or `--rerun` to log the inference results to a Rerun viewer.\n\n### Gradio App\n\nLaunch the local demo app:\n\n```\nuv run --extra app surge-app\n```\n\nThe app lets you upload an image, adjust the token budget and mesh cleanup, view the reconstructed mesh, and download the generated maps and geometry.\n\n### Output Conventions\n\nCoordinate frames:\n\n- `point_map.exr` and `point_normals_map.png`: RDF (OpenCV); `+X` right, `+Y` down, `+Z` forward.\n- `mesh.glb` and `point_cloud.ply`: RUB; `+X` right, `+Y` up, `+Z` backward.\n\nFile formats:\n\n- `point_map.exr`: float32 XYZ points.\n  Masked pixels are `NaN`.\n- `point_normals_map.png`: unit normals.\n  RGB stores `[X, -Y, -Z]` mapped from `[-1, 1]` to `[0, 255]`; invalid pixels are `[127, 127, 127]`.\n  Renormalize after decoding if needed.\n\n## Neighborhood Attention Decoder (NAD) Module\n\nThe [NAD](src\u002Fsurge\u002Fmodules\u002Fheads\u002Fnad.py) is implemented as a reusable PyTorch module.\nIt is intentionally self-contained, so you can be copy it into your project as a single file without pulling in the rest of SurGe.\n\n## ⚖️ License\n\nThe **SurGe code** is released under the MIT license.\nThe **SurGe weights** are released under CC BY-NC 4.0, due to the training datasets used.\n\n## 🙏 Acknowledgments\n\nWe thank the [MoGe](https:\u002F\u002Fgithub.com\u002Fmicrosoft\u002Fmoge) project for their open-source code.\n\n## 🎓 Citation\n\nIf you use our work in your research, please use the following BibTeX entry.\n\n```\n@article{knaebel2026surge,\n    title     = {{SurGe}: Improved Surface Geometry in Point Maps},\n    author    = {Knaebel, Karim and Martin Garcia, Gonzalo and Schmidt, Christian and Fradlin, Ilya and Nunes, Lucas and de Geus, Daan and Leibe, Bastian},\n    year      = 2026,\n    journal   = {arXiv preprint arXiv:2605.31577},\n}\n```\n","2026-06-11 04:10:49","CREATED_QUERY"]