Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ CUDA_VISIBLE_DEVICES=0 nohup python apps/image_to_3d.py > /dev/null 2>&1 &
Generate physically plausible 3D assets from image input via the command-line API.
```sh
img3d-cli --image_path apps/assets/example_image/sample_00.jpg apps/assets/example_image/sample_01.jpg \
--n_retry 1 --output_root outputs/imageto3d
--n_retry 2 --output_root outputs/imageto3d

# See result(.urdf/mesh.obj/mesh.glb/gs.ply) in ${output_root}/sample_xx/result
```
Expand Down Expand Up @@ -246,7 +246,7 @@ Remove `--insert_robot` if you don't consider the robot pose in layout generatio
CUDA_VISIBLE_DEVICES=0 nohup layout-cli \
--task_descs "apps/assets/example_layout/task_list.txt" \
--bg_list "outputs/bg_scenes/scene_list.txt" \
--n_image_retry 4 --n_asset_retry 3 --n_pipe_retry 2 \
--n_image_retry 4 --n_asset_retry 3 --n_pipe_retry 3 \
--output_root "outputs/layouts_gens" --insert_robot > layouts_gens.log &
```

Expand Down
2 changes: 1 addition & 1 deletion docs/tutorials/image_to_3d.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ Support the use of [SAM3D](https://github.com/facebookresearch/sam-3d-objects) o
```bash
img3d-cli --image_path apps/assets/example_image/sample_00.jpg \
apps/assets/example_image/sample_01.jpg \
--n_retry 1 --output_root outputs/imageto3d
--n_retry 2 --output_root outputs/imageto3d
```

You will get the following results:
Expand Down
2 changes: 1 addition & 1 deletion docs/tutorials/layout_gen.md
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ You can also run multiple tasks via a task list file in the backend.
CUDA_VISIBLE_DEVICES=0 nohup layout-cli \
--task_descs "apps/assets/example_layout/task_list.txt" \
--bg_list "outputs/bg_scenes/scene_list.txt" \
--n_image_retry 4 --n_asset_retry 3 --n_pipe_retry 2 \
--n_image_retry 4 --n_asset_retry 3 --n_pipe_retry 3 \
--output_root "outputs/layouts_gens" \
--insert_robot > layouts_gens.log &
```
Expand Down
4 changes: 2 additions & 2 deletions embodied_gen/scripts/imageto3d.py
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ def parse_args():
parser.add_argument(
"--n_retry",
type=int,
default=2,
default=3,
)
parser.add_argument("--disable_decompose_convex", action="store_true")
parser.add_argument("--texture_size", type=int, default=2048)
Expand Down Expand Up @@ -163,7 +163,7 @@ def entrypoint(**kwargs):
outputs = image3d_model_infer(PIPELINE, seg_image, seed)
except Exception as e:
logger.error(
f"[Pipeline Failed] process {image_path}: {e}, skip."
f"[Image3D Failed] process {image_path}: {e}, retry: {try_idx+1}/{args.n_retry}"
)
continue

Expand Down
9 changes: 7 additions & 2 deletions embodied_gen/validators/urdf_convertor.py
Original file line number Diff line number Diff line change
Expand Up @@ -204,8 +204,13 @@ def parse_response(self, response: str) -> dict[str, any]:
Returns:
dict[str, any]: Parsed attributes.
"""
lines = response.split("\n")
lines = [line.strip() for line in lines if line]
raw_lines = response.split("\n")
lines = []
for line in raw_lines:
line = line.strip()
if line and not line.startswith("```") and ":" in line:
lines.append(line)

category = lines[0].split(": ")[1]
description = lines[1].split(": ")[1]
min_height, max_height = map(
Expand Down