Spaces:
Runtime error
Runtime error
Sync latest Qwen example dropdown fixes and add 09 example assets
Browse files
kimodo/assets/demo/examples/kimodo-g1-rp/09_qwen_agentic_actions/meta.json
ADDED
|
@@ -0,0 +1,12 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"text": "Qwen agentic: chain 10 concise action segments for a single character in a coherent scene.",
|
| 3 |
+
"duration": 6.0,
|
| 4 |
+
"num_samples": 1,
|
| 5 |
+
"seed": 42,
|
| 6 |
+
"diffusion_steps": 100,
|
| 7 |
+
"cfg": {
|
| 8 |
+
"enabled": true,
|
| 9 |
+
"text_weight": 2.0,
|
| 10 |
+
"constraint_weight": 2.0
|
| 11 |
+
}
|
| 12 |
+
}
|
kimodo/assets/demo/examples/kimodo-soma-rp/09_qwen_agentic_actions/meta.json
ADDED
|
@@ -0,0 +1,12 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"text": "Qwen agentic: chain 10 concise action segments for a single character in a coherent scene.",
|
| 3 |
+
"duration": 6.0,
|
| 4 |
+
"num_samples": 1,
|
| 5 |
+
"seed": 42,
|
| 6 |
+
"diffusion_steps": 100,
|
| 7 |
+
"cfg": {
|
| 8 |
+
"enabled": true,
|
| 9 |
+
"text_weight": 2.0,
|
| 10 |
+
"constraint_weight": 2.0
|
| 11 |
+
}
|
| 12 |
+
}
|
kimodo/demo/ui.py
CHANGED
|
@@ -47,7 +47,8 @@ from .state import ClientSession
|
|
| 47 |
from kimodo.skeleton import G1Skeleton34, SOMASkeleton30, SOMASkeleton77
|
| 48 |
|
| 49 |
|
| 50 |
-
QWEN_EXAMPLE_NAME = "
|
|
|
|
| 51 |
|
| 52 |
|
| 53 |
def extract_intervals_and_singles(t: torch.Tensor):
|
|
@@ -307,6 +308,8 @@ def create_gui(
|
|
| 307 |
example_names_local = list(new_example_dict.keys())
|
| 308 |
if QWEN_EXAMPLE_NAME not in example_names_local:
|
| 309 |
example_names_local.append(QWEN_EXAMPLE_NAME)
|
|
|
|
|
|
|
| 310 |
gui_examples_dropdown.options = example_names_local
|
| 311 |
if keep_selection and gui_examples_dropdown.value in example_names_local:
|
| 312 |
return
|
|
@@ -2266,7 +2269,7 @@ def create_gui(
|
|
| 2266 |
if session is None:
|
| 2267 |
return
|
| 2268 |
|
| 2269 |
-
if gui_examples_dropdown.value
|
| 2270 |
load_qwen_example_plan(event_client)
|
| 2271 |
return
|
| 2272 |
|
|
|
|
| 47 |
from kimodo.skeleton import G1Skeleton34, SOMASkeleton30, SOMASkeleton77
|
| 48 |
|
| 49 |
|
| 50 |
+
QWEN_EXAMPLE_NAME = "09_qwen_agentic_actions"
|
| 51 |
+
QWEN_EXAMPLE_LEGACY_NAME = "09_qwen_agentic_10_actions"
|
| 52 |
|
| 53 |
|
| 54 |
def extract_intervals_and_singles(t: torch.Tensor):
|
|
|
|
| 308 |
example_names_local = list(new_example_dict.keys())
|
| 309 |
if QWEN_EXAMPLE_NAME not in example_names_local:
|
| 310 |
example_names_local.append(QWEN_EXAMPLE_NAME)
|
| 311 |
+
if QWEN_EXAMPLE_LEGACY_NAME not in example_names_local:
|
| 312 |
+
example_names_local.append(QWEN_EXAMPLE_LEGACY_NAME)
|
| 313 |
gui_examples_dropdown.options = example_names_local
|
| 314 |
if keep_selection and gui_examples_dropdown.value in example_names_local:
|
| 315 |
return
|
|
|
|
| 2269 |
if session is None:
|
| 2270 |
return
|
| 2271 |
|
| 2272 |
+
if gui_examples_dropdown.value in (QWEN_EXAMPLE_NAME, QWEN_EXAMPLE_LEGACY_NAME):
|
| 2273 |
load_qwen_example_plan(event_client)
|
| 2274 |
return
|
| 2275 |
|
kimodo/skeleton/base.py
CHANGED
|
@@ -69,6 +69,11 @@ class SkeletonBase(torch.nn.Module):
|
|
| 69 |
|
| 70 |
if load and folder is not None:
|
| 71 |
pfolder = Path(folder)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 72 |
neutral_joints = torch.load(pfolder / "joints.p").squeeze()
|
| 73 |
self.register_buffer("neutral_joints", neutral_joints, persistent=False)
|
| 74 |
|
|
|
|
| 69 |
|
| 70 |
if load and folder is not None:
|
| 71 |
pfolder = Path(folder)
|
| 72 |
+
if not (pfolder / "joints.p").exists() and self.name is not None:
|
| 73 |
+
fallback_folder = skeleton_asset_path(self.name)
|
| 74 |
+
if (fallback_folder / "joints.p").exists():
|
| 75 |
+
pfolder = fallback_folder
|
| 76 |
+
self.folder = str(pfolder)
|
| 77 |
neutral_joints = torch.load(pfolder / "joints.p").squeeze()
|
| 78 |
self.register_buffer("neutral_joints", neutral_joints, persistent=False)
|
| 79 |
|