va1bhavagrawa1 commited on
Commit
5da6d82
Β·
1 Parent(s): 2793fa3

updated README

Browse files
README.md CHANGED
@@ -20,7 +20,7 @@ tags: # Add extra tags which would make the repo sear
20
 
21
 
22
  <div align="center">
23
- <img src="assets/teaser_camera_ready.svg" width="50%">
24
  </div>
25
 
26
  ## πŸš€ Getting Started
@@ -43,7 +43,7 @@ pip install -e .
43
 
44
  Inference of this model requires ~38 GB VRAM on the GPU. Note that the inference runs Blender in EEVEE mode, which runs faster on workstation GPUs like the NVIDIA RTX A6000, compared to data center GPUs like the NVIDIA H100.
45
 
46
- ### 🌐 Downloading Pre-Crained checkpoint
47
 
48
  We use [FLUX.1-dev](https://huggingface.co/black-forest-labs/FLUX.1-dev) as the base model. To download the SeeThrough3D LoRA checkpoint,
49
  ```bash
@@ -56,7 +56,7 @@ cd checkpoints
56
  ### πŸ€— Gradio Interface
57
 
58
  It is best to perform inference using the πŸ€— Gradio interface, which makes it easy to specify 3D layouts. To launch the interface, run
59
- ```
60
  cd inference
61
  conda activate st3d
62
  python3 app.py
@@ -79,15 +79,21 @@ The inference notebook is located at `infer.ipynb`. It is able to load a scene s
79
 
80
  ## πŸ‹ Training
81
 
82
- ### 🌐 Downloading the Dataset
 
83
 
84
  ```bash
85
  cd dataset
86
-
 
87
  ```
88
 
 
 
89
  ### πŸƒ Run Training
90
 
 
 
91
  We train the model for a single epoch at resolution 512, effective batch size of 2 (~25K steps). This requires 2x 80 GB GPUs (one image per GPU).
92
  ```bash
93
  cd train
 
20
 
21
 
22
  <div align="center">
23
+ <img src="assets/teaser_camera_ready.png" width="50%">
24
  </div>
25
 
26
  ## πŸš€ Getting Started
 
43
 
44
  Inference of this model requires ~38 GB VRAM on the GPU. Note that the inference runs Blender in EEVEE mode, which runs faster on workstation GPUs like the NVIDIA RTX A6000, compared to data center GPUs like the NVIDIA H100.
45
 
46
+ ### 🌐 Download the Pre-Trained Checkpoint
47
 
48
  We use [FLUX.1-dev](https://huggingface.co/black-forest-labs/FLUX.1-dev) as the base model. To download the SeeThrough3D LoRA checkpoint,
49
  ```bash
 
56
  ### πŸ€— Gradio Interface
57
 
58
  It is best to perform inference using the πŸ€— Gradio interface, which makes it easy to specify 3D layouts. To launch the interface, run
59
+ ```bash
60
  cd inference
61
  conda activate st3d
62
  python3 app.py
 
79
 
80
  ## πŸ‹ Training
81
 
82
+ ### 🌐 Download the Dataset
83
+ By default, the data is downloaded in the `dataset` directory. To change the download location, edit the `LOCAL_DIR` variable in `dataset/download.py`.
84
 
85
  ```bash
86
  cd dataset
87
+ conda activate st3d
88
+ ./setup_data.sh
89
  ```
90
 
91
+ We are working on making the data compatible with πŸ€— datasets library for ease of visualization and streaming, see [`va1bhavagrawa1/seethrough3d-data`](https://huggingface.co/datasets/va1bhavagrawa1/seethrough3d-data/tree/main)
92
+
93
  ### πŸƒ Run Training
94
 
95
+ Edit `train/train.sh` to specify the downloaded dataset path.
96
+
97
  We train the model for a single epoch at resolution 512, effective batch size of 2 (~25K steps). This requires 2x 80 GB GPUs (one image per GPU).
98
  ```bash
99
  cd train
assets/teaser_camera_ready.png ADDED

Git LFS Details

  • SHA256: ff4f048fcf998fdb440fbb435593631a29cbc0e3f14d352cfc8a7fa27d118c41
  • Pointer size: 132 Bytes
  • Size of remote file: 1.03 MB
dataset/download.py ADDED
@@ -0,0 +1,17 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ from huggingface_hub import hf_hub_download
2
+ import os
3
+
4
+ LOCAL_DIR = "."
5
+
6
+ repo_id = "va1bhavagrawa1/seethrough3d-data"
7
+ file_in_repo = "seethrough3d_data.tar" # change this
8
+
9
+ local_path = hf_hub_download(
10
+ repo_id=repo_id,
11
+ filename=file_in_repo,
12
+ repo_type="dataset",
13
+ local_dir=LOCAL_DIR, # current directory
14
+ local_dir_use_symlinks=False # makes a real copy (not symlink)
15
+ )
16
+
17
+ print("Downloaded to:", os.path.abspath(local_path))
dataset/setup_data.sh ADDED
@@ -0,0 +1,2 @@
 
 
 
1
+ python3 download.py
2
+ tar -xvf seethrough3d_data.tar
inference/config.py CHANGED
@@ -16,10 +16,9 @@ SAVED_SCENES_DIR = os.path.join(BASE_DIR, "saved_scenes")
16
  PRETRAINED_MODEL_NAME_OR_PATH = "black-forest-labs/FLUX.1-dev"
17
 
18
  # The root directory where LoRA fine-tunes are stored
19
- LORA_WEIGHTS_ROOT = "/archive/vaibhav.agrawal/a-bev-of-the-latents/easycontrol_cuboids"
20
-
21
- # The directory containing cached inference embeddings (if used)
22
- INFERENCE_EMBEDS_DIR = "/archive/vaibhav.agrawal/a-bev-of-the-latents/inference_embeds_flux2"
23
 
24
  # Available Checkpoint weights (dropdown options)
25
  CHECKPOINT_NAMES = [
 
16
  PRETRAINED_MODEL_NAME_OR_PATH = "black-forest-labs/FLUX.1-dev"
17
 
18
  # The root directory where LoRA fine-tunes are stored
19
+ LORA_WEIGHTS_ROOT = os.path.join(os.path.dirname(BASE_DIR), "checkpoints")
20
+ if not os.path.exists(LORA_WEIGHTS_ROOT):
21
+ raise FileNotFoundError(f"LoRA weights root directory not found: {LORA_WEIGHTS_ROOT}")
 
22
 
23
  # Available Checkpoint weights (dropdown options)
24
  CHECKPOINT_NAMES = [
train/train.sh CHANGED
@@ -1,7 +1,7 @@
1
  export MODEL_DIR="black-forest-labs/FLUX.1-dev" # your flux path
2
- export OUTPUT_DIR="/archive/vaibhav.agrawal/a-bev-of-the-latents/checkpoints" # your save path
3
  export CONFIG="./default_config.yaml"
4
- export TRAIN_DATA="/archive/vaibhav.agrawal/a-bev-of-the-latents/seethrough3d_data/train.jsonl" # your data jsonl file
5
  export LOG_PATH="$OUTPUT_DIR/log"
6
 
7
  accelerate launch --config_file $CONFIG train.py \
 
1
  export MODEL_DIR="black-forest-labs/FLUX.1-dev" # your flux path
2
+ export OUTPUT_DIR="../checkpoints" # your save path
3
  export CONFIG="./default_config.yaml"
4
+ export TRAIN_DATA="../dataset/seethrough3d_data/train.jsonl" # your data jsonl file
5
  export LOG_PATH="$OUTPUT_DIR/log"
6
 
7
  accelerate launch --config_file $CONFIG train.py \