Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
db343e1
add motor simulator
hoanglmv Sep 23, 2026
9895ce2
Update simulator to OpenArm Bimanual (Dual 7-DOF arms with 16 Damiao …
hoanglmv Sep 23, 2026
af063f7
Add no-cache headers and cache busters for Bimanual OpenArm UI
hoanglmv Sep 23, 2026
cff489b
update
hoanglmv Sep 23, 2026
ff9fc50
Add GitHub Ruleset to protect main branch (single-owner merge, no pee…
hoanglmv Sep 23, 2026
d756fd3
Refactor UI: remove all emoji/AI icons, ensure flat solid design, add…
hoanglmv Sep 24, 2026
c8c2fd3
Add Docker and Docker Compose configuration for OpenArm CAN and Web D…
hoanglmv Sep 24, 2026
975e450
Update Joint 8 Gripper to horizontal parallel prismatic slider (strok…
hoanglmv Sep 24, 2026
588dfd7
Add real-time bi-directional Digital Twin synchronization for sliders…
hoanglmv Sep 24, 2026
bfe56cf
fix(sim): restore left arm joint2 limits to (-0.1745, 3.3161) and upd…
hoanglmv Sep 24, 2026
274fede
feat(config): sync exact joint limits q_min, q_max for joint1-7 in se…
hoanglmv Sep 24, 2026
bf6cc73
update
hoanglmv Sep 24, 2026
11e4b7c
fix(sim): update J2 kinematics and slider limits to prevent arm crossing
hoanglmv Sep 24, 2026
50fc526
update
hoanglmv Sep 24, 2026
19633da
update
hoanglmv Sep 24, 2026
fa1b9c8
Merge pull request #1 from hoanglmv/hoanglmv
hoanglmv Sep 24, 2026
277b945
Fix connect_robot script and update gitignore
leekwanreal Sep 24, 2026
8058d18
feat(act): add complete ACT cloth folding pipeline, docs, and trainin…
leekwanreal Sep 24, 2026
41725da
Clean earlier commit
leekwanreal Sep 24, 2026
e4abb89
feat(act): complete ACT bimanual pipeline, training, eval and hardwar…
leekwanreal Sep 24, 2026
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
14 changes: 14 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
.git
.github
build
dist
*.egg-info
__pycache__
*.pyc
*.pyo
*.pyd
.venv*
venv*
.cache
.system_generated
*.log
49 changes: 49 additions & 0 deletions .github/rulesets/main-protection-ruleset.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
{
"name": "Protect main branch - Only Owner can merge",
"target": "branch",
"enforcement": "active",
"conditions": {
"ref_name": {
"include": [
"~DEFAULT_BRANCH"
],
"exclude": []
}
},
"rules": [
{
"type": "deletion"
},
{
"type": "non_fast_forward"
},
{
"type": "pull_request",
"parameters": {
"required_approving_review_count": 0,
"dismiss_stale_reviews_on_push": false,
"require_code_owner_review": false,
"require_last_push_approval": false,
"required_review_thread_resolution": false,
"require_extra_approval_for_unattributed_changes": false,
"allowed_merge_methods": [
"merge",
"squash",
"rebase"
]
}
}
],
"bypass_actors": [
{
"actor_id": 5,
"actor_type": "RepositoryRole",
"bypass_mode": "always"
},
{
"actor_id": 131538387,
"actor_type": "User",
"bypass_mode": "always"
}
]
}
11 changes: 11 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -31,3 +31,14 @@
/packages/yum/tmp/
/python/dist/
/python/vendor/
__pycache__/
*.pyc
SETUP_WSL_GUIDE.md
*.local.md
test_wrist_pitch.py
stop_robot.py
.venv*/
dataset/
*.pth
*.hdf5

239 changes: 239 additions & 0 deletions ACT_ARCHITECTURE.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,239 @@
<!DOCTYPE html>
<html lang="vi">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Mô Hình ACT Gọn (RGB-D + 16-DOF Bimanual)</title>
<script src="https://cdn.jsdelivr.net/npm/mermaid/dist/mermaid.min.js"></script>
<style>
:root {
--bg: #070b14;
--card: #0d1527;
--border: #1e293b;
--text: #f8fafc;
--muted: #94a3b8;
--fire: #f97316;
--ice: #38bdf8;
--purple: #c084fc;
--green: #34d399;
}

* { box-sizing: border-box; }

body {
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
background: radial-gradient(circle at 50% 10%, #111a36 0%, var(--bg) 75%);
color: var(--text);
margin: 0;
padding: 12px 16px;
height: 100vh;
display: flex;
flex-direction: column;
justify-content: space-between;
overflow: hidden;
}

/* HEADER */
.header {
display: flex;
align-items: center;
justify-content: space-between;
border-bottom: 1px solid var(--border);
padding-bottom: 8px;
margin-bottom: 8px;
}
.header-left h1 {
font-size: 17px;
margin: 0;
font-weight: 800;
background: linear-gradient(90deg, #38bdf8, #f97316);
-webkit-background-clip: text;
-webkit-text-fill-color: transparent;
letter-spacing: -0.3px;
}
.header-left p {
margin: 2px 0 0 0;
font-size: 11px;
color: var(--muted);
}
.badge-group {
display: flex;
gap: 6px;
}
.badge {
font-size: 10px;
padding: 3px 8px;
border-radius: 9999px;
font-weight: 600;
border: 1px solid;
}
.badge.ice { border-color: rgba(56, 189, 248, 0.4); color: var(--ice); background: rgba(56, 189, 248, 0.1); }
.badge.fire { border-color: rgba(249, 115, 22, 0.4); color: var(--fire); background: rgba(249, 115, 22, 0.1); }
.badge.green { border-color: rgba(52, 211, 153, 0.4); color: var(--green); background: rgba(52, 211, 153, 0.1); }

/* MERMAID WRAPPER */
.mermaid-box {
flex: 1;
display: flex;
align-items: center;
justify-content: center;
background: rgba(13, 21, 39, 0.7);
border: 1px solid var(--border);
border-radius: 12px;
padding: 6px 12px;
box-shadow: 0 15px 35px -10px rgba(0,0,0,0.8);
position: relative;
}
.mermaid {
width: 100%;
display: flex;
justify-content: center;
}

/* FOOTER MICRO-CARDS */
.footer-grid {
display: grid;
grid-template-columns: repeat(4, 1fr);
gap: 8px;
margin-top: 8px;
}
.m-card {
background: var(--card);
border: 1px solid var(--border);
border-radius: 8px;
padding: 8px 10px;
}
.m-card h4 {
margin: 0 0 3px 0;
font-size: 11px;
display: flex;
align-items: center;
gap: 5px;
}
.m-card p {
margin: 0;
font-size: 10px;
color: var(--muted);
line-height: 1.4;
}
.m-card.c-in h4 { color: var(--text); }
.m-card.c-fire h4 { color: var(--fire); }
.m-card.c-ice h4 { color: var(--ice); }
.m-card.c-out h4 { color: var(--green); }
</style>
</head>
<body>

<!-- HEADER -->
<div class="header">
<div class="header-left">
<h1>KIẾN TRÚC MÔ HÌNH ACT — OPENARM 16-DOF</h1>
<p>01 Camera Ngực RGB-D + Hai Cánh Tay Robot (16 Motors) • Chunking k=50 @ 50Hz</p>
</div>
<div class="badge-group">
<span class="badge ice">❄️ Fixed / Frozen</span>
<span class="badge fire">🔥 Trainable</span>
<span class="badge green">🦾 16-DOF CAN-FD</span>
</div>
</div>

<!-- COMPACT MERMAID DIAGRAM -->
<div class="mermaid-box">
<div class="mermaid">
%%{init: {'theme': 'dark', 'themeVariables': { 'fontSize': '11.5px', 'fontFamily': 'system-ui, sans-serif' }}}%%
flowchart LR

%% 1. ĐẦU VÀO
subgraph S1 ["1. ĐẦU VÀO (Observation)"]
direction TB
RGBD["📷 <b>Camera Ngực RGB-D</b><br/>[4, 480, 640] ❄️"]
QPOS["🦾 <b>Khớp Hiện Tại (qpos)</b><br/>16 Khớp [16] ❄️"]
end

%% 2. THỊ GIÁC & CVAE
subgraph S2 ["2. THỊ GIÁC & CVAE"]
direction TB
CONV["🔥 <b>4-Ch Conv1</b> (RGB+D)"]
RES["❄️ <b>ResNet-18</b> (Layers 1..4)<br/><i>(Pretrained Frozen)</i>"]
VTOK["<b>300 Visual Tokens</b><br/>[300, 512]"]
QPROJ["🔥 <b>Joint Proj</b> (16 ➔ 512)"]
CVAE["🔥 <b>CVAE Block</b><br/>• Train: z ~ N(μ, σ²)<br/>• <b>Test: z = 0 ❄️</b>"]
end

%% 3. TRANSFORMER POLICY
subgraph S3 ["3. TRANSFORMER POLICY"]
direction TB
MEM["<b>302 Memory Tokens</b><br/>(300 Vis + 1 Qpos + 1 z)"]
QRY["🔥 <b>50 Action Queries</b><br/>[50, 512] + 1D PE ❄️"]
DEC["🔥 <b>Decoder (4 Layers)</b><br/>Cross/Self-Attention"]
HEAD["🔥 <b>Linear Head</b> (512 ➔ 16)"]
end

%% 4. ĐIỀU KHIỂN CAN BUS
subgraph S4 ["4. ĐẦU RA & CAN-FD"]
direction TB
CHUNK["🎯 <b>Action Chunk [50, 16]</b><br/>Quỹ đạo 50 bước tương lai"]
ENS["❄️ <b>Temporal Ensemble</b><br/>Bộ lọc làm mịn mũ"]
CAN["⚡ <b>SocketCAN (can0)</b><br/>16 Motor Damiao @ 50Hz"]
end

%% KẾT NỐI
RGBD --> CONV --> RES --> VTOK --> MEM
QPOS --> QPROJ --> MEM
QPOS -.-> CVAE --> MEM
MEM --> DEC
QRY --> DEC --> HEAD --> CHUNK
CHUNK --> ENS --> CAN

%% STYLING
classDef fire fill:#3d1308,stroke:#f97316,stroke-width:2px,color:#fed7aa;
classDef ice fill:#082f49,stroke:#38bdf8,stroke-width:2px,color:#e0f2fe;
classDef mem fill:#2e1065,stroke:#a855f7,stroke-width:1.5px,color:#f3e8ff;
classDef out fill:#064e3b,stroke:#34d399,stroke-width:2px,color:#d1fae5;
classDef inp fill:#0f172a,stroke:#64748b,stroke-width:1.5px,color:#f8fafc;

class RGBD,QPOS inp;
class CONV,QPROJ,CVAE,QRY,DEC,HEAD fire;
class RES,ENS,CAN ice;
class VTOK,MEM mem;
class CHUNK out;
</div>
</div>

<!-- FOOTER SUMMARY CARDS -->
<div class="footer-grid">
<div class="m-card c-in">
<h4>📷 1. Đầu Vào Tinh Gọn</h4>
<p>• <b>RGB-D (4 kênh)</b>: 3 màu + 1 chiều sâu Z.<br/>• <b>qpos (16)</b>: 8 khớp Trái + 8 khớp Phải.</p>
</div>

<div class="m-card c-fire">
<h4>🔥 2. Khối Trainable (Lửa)</h4>
<p>• <b>Conv1 Adapter</b> + <b>Joint Proj</b>.<br/>• <b>CVAE Encoder</b> + <b>Queries</b> + <b>Decoder 4 lớp</b>.</p>
</div>

<div class="m-card c-ice">
<h4>❄️ 3. Khối Fixed (Tuyết)</h4>
<p>• <b>ResNet-18 Frozen</b> (chống overfit).<br/>• <b>z = 0</b> lúc test + <b>PE sin/cos</b> + <b>Ensemble</b>.</p>
</div>

<div class="m-card c-out">
<h4>🎯 4. Đầu Ra 16 Khớp (50Hz)</h4>
<p>• <b>Chunk [50, 16]</b>: 1s chuyển động 2 tay.<br/>• Gửi 16 gói tin MIT Mode qua <b>SocketCAN</b>.</p>
</div>
</div>

<script>
mermaid.initialize({
startOnLoad: true,
theme: 'dark',
securityLevel: 'loose',
flowchart: {
useMaxWidth: false,
htmlLabels: true,
curve: 'basis'
}
});
</script>
</body>
</html>
Loading