[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"project-78600":3},{"id":4,"name":5,"fullName":6,"owner":7,"repo":5,"description":8,"homepage":8,"htmlUrl":8,"language":9,"languages":8,"totalLinesOfCode":8,"stars":10,"forks":11,"watchers":12,"openIssues":13,"contributorsCount":14,"subscribersCount":14,"size":14,"stars1d":15,"stars7d":16,"stars30d":17,"stars90d":14,"forks30d":14,"starsTrendScore":18,"compositeScore":19,"rankGlobal":8,"rankLanguage":8,"license":8,"archived":20,"fork":20,"defaultBranch":21,"hasWiki":22,"hasPages":20,"topics":23,"createdAt":8,"pushedAt":8,"updatedAt":24,"readmeContent":25,"aiSummary":26,"trendingCount":14,"starSnapshotCount":14,"syncStatus":27,"lastSyncTime":28,"discoverSource":29},78600,"GenCAD","ferdous-alam\u002FGenCAD","ferdous-alam",null,"Python",3333,407,50,29,0,52,172,261,156,103.83,false,"main",true,[],"2026-06-12 04:01:23","\u003Cp align=\"center\">\n  \u003Ch1 align=\"center\">GenCAD\u003C\u002Fh1>\n  \u003Ch4 align=\"center\">Image-conditioned Computer-Aided Design Generation with Transformer-based Contrastive Representation and Diffusion Priors\u003C\u002Fh4>\n\u003C\u002Fp>\n\n\u003Cp align=\"center\">\n  \u003Ca href=\"https:\u002F\u002Fopenreview.net\u002Fpdf?id=e817c1wEZ6\">\n    \u003Cimg src=\"https:\u002F\u002Fimg.shields.io\u002Fbadge\u002FPaper-TMLR%202025-4b44ce.svg\">\n  \u003C\u002Fa>\n  \u003Ca href=\"https:\u002F\u002Farxiv.org\u002Fabs\u002F2409.16294\">\n    \u003Cimg src=\"https:\u002F\u002Fimg.shields.io\u002Fbadge\u002FarXiv-2409.16294-b31b1b.svg\">\n  \u003C\u002Fa>\n  \u003Ca href=\"https:\u002F\u002Fgencad.github.io\u002F\">\n    \u003Cimg src=\"https:\u002F\u002Fimg.shields.io\u002Fbadge\u002FProject%20Page-Link-blue\">\n  \u003C\u002Fa>\n\u003C\u002Fp>\n\n---\n\n\u003Cp align=\"center\">\n  \u003Cimg src=\"assets\u002Ffig_10.png\" alt=\"GenCAD Demo\" width=\"700\"\u002F>\n\u003C\u002Fp>\n\n---\n\n## 📁 Dataset \n\nDownload from [here](https:\u002F\u002Fdrive.google.com\u002Fdrive\u002Ffolders\u002F1M0dPr5kILGY9HTRCHox1vLLDhhxJWl_C?usp=sharing) and place it in the `data\u002F` directory. \n\n---\n\n## 📦 Pretrained Models\n\nDownload from [here](https:\u002F\u002Fdrive.google.com\u002Fdrive\u002Ffolders\u002F1Ej7wdtlqT5P-SoUf3gsZXD8b78XqhiI5?usp=sharing) and place them in `data\u002Fckpt\u002F`.\n\n---\n\n## 🔧 Setup Options\n\nFirst download the checkpoints and the dataset and put them in their respective directories. \n\n### Option 1: Docker (Recommended)\n\n1. Clone the repo:\n   ```bash\n   git clone https:\u002F\u002Fgithub.com\u002Fferdous-alam\u002FGenCAD\n   cd GenCAD\n   ```\n\n2. Build the Docker image:\n   ```bash\n   docker build -t gencad:latest .\n   ```\n\n3. Run a script, for example training CSR:\n   ```bash\n   docker run -it gencad:latest conda run -n gencad_env python train_gencad.py csr -name test -gpu 0\n   ```\n4. For headless visualization (inference):\n\n   First, enter the container with GPU access and mount the appropriate folders:\n\n   ```bash\n   docker run --gpus all \\\n     -v $(pwd)\u002Fdata\u002Fimages:\u002Fapp\u002Fdata\u002Fimages \\\n     -v $(pwd)\u002Fassets:\u002Fapp\u002Fassets \\\n     -v $(pwd)\u002Fresults:\u002Fapp\u002Fresults \\\n     -it gencad:latest \u002Fbin\u002Fbash\n   ```\n\n   Then inside the container, run:\n\n   ```bash\n   xvfb-run --server-args=\"-screen 0 2048x2048x24\" python inference_gencad.py -image_path data\u002Fimages -export_img\n   ```\n---\n\n### Option 2: Manual (conda + pip)\n\n\n1. Create and activate a virtual environment with GPU support:\n   ```bash\n   conda create -n gencad_env python=3.10 -y\n   conda activate gencad_env\n\n2. Install `pythonocc-core` using conda:\n   ```bash\n   conda install -c conda-forge pythonocc-core=7.9.0\n   ```\n\n3. Install the rest via pip:\n   ```bash\n   pip install -r requirements.txt\n   ```\n\n4. Now run training or inference:\n   ```bash\n   python train_gencad.py csr -name test -gpu 0\n   ```\n\n---\n\n## 🚀 Training\n\n### CSR Model\n```bash\npython train_gencad.py csr -name test -gpu 0\n```\nOptional checkpoint:\n```bash\npython train_gencad.py csr -name test -gpu 0 -ckpt \"model\u002Fckpt\u002Fae_ckpt_epoch1000.pth\"\n```\n\n### CCIP Model\n```bash\npython train_gencad.py ccip -name test -gpu 0 -cad_ckpt \"model\u002Fckpt\u002Fae_ckpt_epoch1000.pth\"\n```\n\n### Diffusion Prior\n```bash\npython train_gencad.py dp -name test -gpu 0 -cad_emb 'data\u002Fembeddings\u002Fcad_embeddings.h5' -img_emb 'data\u002Fembeddings\u002Fsketch_embeddings.h5'\n```\n\n---\n\n## 🧪 Inference\n\nFor headless systems (e.g. servers):\n\n```bash\nxvfb-run python inference_gencad.py\n```\n\n---\n\n## 🖼 STL Visualization\n\nConvert STL to PNG:\n```bash\npython stl2img.py -src path\u002Fto\u002Fstl\u002Ffiles -dst path\u002Fto\u002Fsave\u002Fimages\n```\n\n---\n\n## 📊 Evaluation\n\nComing soon.\n","GenCAD 是一个基于Transformer对比表示和扩散先验的图像条件计算机辅助设计生成工具。其核心功能在于通过先进的深度学习技术，将输入的图像转化为对应的CAD模型，支持CSR（对比表示）与CCIP（对比图像-点云）模型训练以及使用扩散先验进行更精细的设计调整。该项目利用Python开发，并提供Docker镜像以简化部署过程，同时也支持手动配置环境的方式运行。适合于需要根据草图或概念图快速生成初步3D模型的设计场景，如工业设计、建筑设计等领域。",2,"2026-06-11 03:56:56","high_star"]