You must provide either asset IDs or direct S3 keys for both input files:
Option 1: Asset ID (Recommended)
job = client.jobs.start_retarget(
c3d_asset_id="uuid",
markerset_asset_id="uuid"
)
Option 2: Direct S3 Key
job = client.jobs.start_retarget(
c3d_s3="s3://bucket/path/to/file.c3d",
markerset_s3="s3://bucket/path/to/markerset.xml"
)
Requirements:
Requirements:
Checking available versions:
character = client.characters.get(character_id)
for version in character["ready_versions"]:
print(f"Version {version['version']}: {version['status']}")
Whether to enable body scaling during retargeting.
Default: True
Type: bool
Example:
# Enable scaling (default)
job = client.jobs.start_retarget(
c3d_asset_id=c3d_id,
markerset_asset_id=markerset_id,
enable_scaling=True
)
# Disable scaling
job = client.jobs.start_retarget(
c3d_asset_id=c3d_id,
markerset_asset_id=markerset_id,
enable_scaling=False
)
When to disable:
Subject gender for anthropometric scaling.
Default: "male"
Type: Literal["male", "female"]
Example:
job = client.jobs.start_retarget(
c3d_asset_id=c3d_id,
markerset_asset_id=markerset_id,
subject_gender="female"
)
Impact:
Subject height in meters for anthropometric scaling.
Default: None (estimated from motion data)
Type: float | None
Example:
job = client.jobs.start_retarget(
c3d_asset_id=c3d_id,
markerset_asset_id=markerset_id,
subject_height=1.75 # 175 cm
)
When to specify:
Note: If not provided, height is estimated from the motion data.
Subject weight in kilograms for anthropometric scaling.
Default: None (estimated from motion data)
Type: float | None
Example:
job = client.jobs.start_retarget(
c3d_asset_id=c3d_id,
markerset_asset_id=markerset_id,
subject_weight=70.0 # 70 kg
)
When to specify:
Note: If not provided, weight is estimated from the motion data.
Optional metadata dictionary for tracking and organization.
Default: None
Type: dict[str, Any] | None
Example:
job = client.jobs.start_retarget(
c3d_asset_id=c3d_id,
markerset_asset_id=markerset_id,
metadata={
"project": "game_animation",
"scene": "walking_sequence",
"subject": "actor_001",
"notes": "First take"
}
)
Use cases:
Note: Metadata is stored with the job and can be retrieved later via client.jobs.get(job_id).
import os
from myosdk import Client
client = Client(api_key=os.getenv("MYOSDK_API_KEY"))
# Upload input files
c3d_asset = client.assets.upload_file("motion.c3d")
markerset_asset = client.assets.upload_file("markerset.xml")
# Start retarget job with all parameters
job = client.jobs.start_retarget(
c3d_asset_id=c3d_asset["asset_id"],
markerset_asset_id=markerset_asset["asset_id"],
enable_scaling=True,
subject_gender="male",
subject_height=1.75,
subject_weight=70.0,
metadata={
"project": "animation_pipeline",
"subject": "actor_001"
}
)
# Wait for completion
result = client.jobs.wait(job["job_id"])
# Download result
output_asset_id = result["output"]["retarget_output_asset_id"]
client.assets.download(output_asset_id, "output.npz")
"retarget""completed" statussubject_gender is exactly "male" or "female"subject_height and subject_weight are positive numbers