Skip to content

Add RobertEngineV10 fabric physics engine#115

Draft
Copilot wants to merge 2 commits intomainfrom
copilot/add-pilot-collection-feature
Draft

Add RobertEngineV10 fabric physics engine#115
Copilot wants to merge 2 commits intomainfrom
copilot/add-pilot-collection-feature

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Apr 7, 2026

Implements the RobertEngineV10 class — a fabric physics simulation engine for TRYONYOU's virtual try-on pipeline (Patent PCT/EP2025/067317).

New: api/robert_engine.py

Four simulation modules:

  • Fabric Physics (_calculate_physics) — Lafayette Factor (drape-based width expansion), Gravity Stretch (up to 15% elongation by GSM), Elasticity Breathing (sinusoidal oscillation)
  • Visual Effects (_get_visual_effects) — Silk highlight for friction < 0.35, fold shadows (3 or 5 by drape threshold), golden scan line on a 2 000 ms cycle when fit_score < 95
  • Accessory Rendering (get_accessory_render) — Body-anchored (80% of shoulder width) or floating-exhibition mode (18% of canvas), fixed alpha=0.88
  • Frame Processing (process_frame) — Orchestrates the above, returns a signed buffer with patent metadata including recovery_status (STABLE/DEGRADED based on fabric recovery > 85)
engine = RobertEngineV10()
result = engine.process_frame(
    look_id="eg0",       # Silk Haussmann
    shoulder_w=450,
    hip_y=900,
    fit_score=88,        # triggers golden scan line
    canvas_dim={"w": 1080, "h": 1920},
)
# result["metadata"]["patent"] == "PCT/EP2025/067317"
# result["metadata"]["recovery_status"] == "STABLE"

The PILOT_COLLECTION class attribute defines 5 pilot looks (eg0eg4) with per-fabric parameters: drape, gsm, elasticity, recovery, friction. Unknown look_id values fall back silently to eg0.

New: tests/test_robert_engine.py

36 unit tests across all modules — pilot collection integrity, physics outputs, visual effect triggers, accessory dimension/mode logic, and frame metadata correctness.

@vercel
Copy link
Copy Markdown

vercel bot commented Apr 7, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
tryonyou-pilot Error Error Apr 7, 2026 1:57pm

Request Review

Copilot AI changed the title [WIP] Add pilot collection feature to RobertEngineV10 Add RobertEngineV10 fabric physics engine Apr 7, 2026
Copilot AI requested a review from LVT-ENG April 7, 2026 13:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants