Invoke is a leading creative engine that uses image and video generation models to empower professionals, artists, and enthusiasts to generate and create visual media using the latest AI-driven technologies. The solution offers an industry-leading application interface, and serves as the foundation for multiple commercial products.
TypeScript ai-artartificial-intelligencegenerative-artimage-generationimg2imginpaintinglatent-diffusionlinuxmacosoutpaintingstable-diffusiontxt2imgwindows
chore(perf): record the upgrade's route bytes and lazier canvas modules
Josh Corbettfac33a9b5e30
diff --git a/invokeai/frontend/webv2/performance/README.md b/invokeai/frontend/webv2/performance/README.mdindex b6af3f186a..fc65fb1ffe 100644--- a/invokeai/frontend/webv2/performance/README.md+++ b/invokeai/frontend/webv2/performance/README.md@@ -62,7 +62,7 @@ Locale strings count: `en.json` is part of each route's `otherAssetRawBytes`. Ne### Finding a new startup request-Build `main` in a separate worktree; compare hash-stripped `dist/assets/*.js` names with the branch build. Names only in the branch build that also appear in the route trace (`artifacts/architecture-performance/traces/<fixture>-<profile>.zip`, `trace.network` URLs) are the extra requests. Run `pnpm test:performance:browser:profile` to collect traces for passing routes. `dist/.vite/chunk-sources.json` maps chunks to sources; `vite build --minify false` keeps `//#region` module markers.+Build `main` in a separate worktree; compare hash-stripped `dist/assets/*.js` names with the branch build. Names only in the branch build that also appear in the route trace (`artifacts/architecture-performance/traces/<fixture>-<profile>.zip`, `trace.network` URLs) are the extra requests. Run `pnpm test:performance:browser:profile` to collect traces for passing routes. `dist/.vite/chunk-sources.json` maps each chunk to its source modules and packages; diff it between the two builds to see which modules moved between chunks. Unminified builds no longer carry `//#region` module markers.## Remediation ticketsdiff --git a/invokeai/frontend/webv2/performance/architecture-baseline.json b/invokeai/frontend/webv2/performance/architecture-baseline.jsonindex edcdf69039..e2ae45f1d6 100644--- a/invokeai/frontend/webv2/performance/architecture-baseline.json+++ b/invokeai/frontend/webv2/performance/architecture-baseline.json@@ -2,15 +2,15 @@"build": {"launchpad": {"baseline": {- "brotliBytes": 802380,+ "brotliBytes": 807902,"cssRawBytes": 2159,"fontRawBytes": 219480,- "gzipBytes": 801520,+ "gzipBytes": 806960,"imageRawBytes": 44398,- "initialRawBytes": 2066324,- "largestAssetRawBytes": 752422,+ "initialRawBytes": 2082351,+ "largestAssetRawBytes": 751904,"otherAssetRawBytes": 0,- "ownedRawBytes": 101787,+ "ownedRawBytes": 103023,"requestCount": 35,"scriptRequestCount": 19,"sourceOwners": [@@ -350,15 +350,15 @@},"editor": {"baseline": {- "brotliBytes": 1201065,+ "brotliBytes": 1208932,"cssRawBytes": 2159,"fontRawBytes": 219480,- "gzipBytes": 1194189,+ "gzipBytes": 1201383,"imageRawBytes": 44398,- "initialRawBytes": 3306361,- "largestAssetRawBytes": 752422,+ "initialRawBytes": 3328932,+ "largestAssetRawBytes": 751904,"otherAssetRawBytes": 0,- "ownedRawBytes": 155629,+ "ownedRawBytes": 156396,"requestCount": 71,"scriptRequestCount": 55,"sourceOwners": [@@ -843,12 +843,10 @@"source:src/workbench/canvas-engine/document/mergeVisible.ts","source:src/workbench/canvas-engine/document/selectionRepair.ts","source:src/workbench/canvas-engine/document/sources.ts",- "source:src/workbench/canvas-engine/editing/controlPixelEdit.ts","source:src/workbench/canvas-engine/engineStores.ts","source:src/workbench/canvas-engine/layerExportGuards.ts","source:src/workbench/canvas-engine/math/mat2d.ts","source:src/workbench/canvas-engine/math/rect.ts",- "source:src/workbench/canvas-engine/math/snapping.ts","source:src/workbench/canvas-engine/mutationContracts.ts","source:src/workbench/canvas-engine/render/adjustments.ts","source:src/workbench/canvas-engine/render/compositor.ts",@@ -857,7 +855,6 @@"source:src/workbench/canvas-engine/render/maskFill.ts","source:src/workbench/canvas-engine/render/rasterComposite.ts","source:src/workbench/canvas-engine/render/rasterizers/textRasterizer.ts",- "source:src/workbench/canvas-engine/transform/transformMath.ts","source:src/workbench/canvasDimsSync.ts","source:src/workbench/canvasLayerContent.ts","source:src/workbench/canvasMigration.ts",diff --git a/invokeai/frontend/webv2/performance/browser-baseline.json b/invokeai/frontend/webv2/performance/browser-baseline.jsonindex f83b5c8d8f..06d8d038ca 100644--- a/invokeai/frontend/webv2/performance/browser-baseline.json+++ b/invokeai/frontend/webv2/performance/browser-baseline.json@@ -29,12 +29,12 @@"cssRawBytes": 2159,"fontRawBytes": 23664,"imageRawBytes": 0,- "largestAssetRawBytes": 752413,- "otherRawBytes": 226185,+ "largestAssetRawBytes": 751904,+ "otherRawBytes": 227475,"requestCount": 29,- "scriptRawBytes": 1868300,+ "scriptRawBytes": 1890448,"scriptRequestCount": 25,- "totalRawBytes": 2120308+ "totalRawBytes": 2143746},"routeReadyMedianMs": 215.30000019073486,"scriptSourceOwnerSet": "launchpad-static",@@ -67,12 +67,12 @@"cssRawBytes": 2159,"fontRawBytes": 23664,"imageRawBytes": 0,- "largestAssetRawBytes": 752413,- "otherRawBytes": 226185,+ "largestAssetRawBytes": 751904,+ "otherRawBytes": 227475,"requestCount": 29,- "scriptRawBytes": 1868300,+ "scriptRawBytes": 1890448,"scriptRequestCount": 25,- "totalRawBytes": 2120308+ "totalRawBytes": 2143746},"routeReadyMedianMs": 225.39999961853027,"scriptSourceOwnerSet": "launchpad-static",@@ -105,12 +105,12 @@"cssRawBytes": 2159,"fontRawBytes": 23664,"imageRawBytes": 44398,- "largestAssetRawBytes": 752413,- "otherRawBytes": 226185,+ "largestAssetRawBytes": 751904,+ "otherRawBytes": 227469,"requestCount": 87,- "scriptRawBytes": 4199867,+ "scriptRawBytes": 4238288,"scriptRequestCount": 82,- "totalRawBytes": 4496273+ "totalRawBytes": 4535978},"routeReadyMedianMs": 360.90000009536743,"scriptSourceOwnerSet": "editor-minimal-static",@@ -143,12 +143,12 @@"cssRawBytes": 2159,"fontRawBytes": 23664,"imageRawBytes": 44398,- "largestAssetRawBytes": 752413,- "otherRawBytes": 226185,+ "largestAssetRawBytes": 751904,+ "otherRawBytes": 227469,"requestCount": 87,- "scriptRawBytes": 4199867,+ "scriptRawBytes": 4238288,"scriptRequestCount": 82,- "totalRawBytes": 4496273+ "totalRawBytes": 4535978},"routeReadyMedianMs": 367.80000019073486,"scriptSourceOwnerSet": "editor-minimal-static",@@ -181,12 +181,12 @@"cssRawBytes": 2159,"fontRawBytes": 23664,"imageRawBytes": 44398,- "largestAssetRawBytes": 752413,- "otherRawBytes": 226185,+ "largestAssetRawBytes": 751904,+ "otherRawBytes": 227469,"requestCount": 96,- "scriptRawBytes": 4718489,+ "scriptRawBytes": 4760595,"scriptRequestCount": 91,- "totalRawBytes": 5014895+ "totalRawBytes": 5058285},"routeReadyMedianMs": 1095.3000001907349,"scriptSourceOwnerSet": "editor-canvas-static",@@ -219,12 +219,12 @@"cssRawBytes": 2159,"fontRawBytes": 23664,"imageRawBytes": 44398,- "largestAssetRawBytes": 752413,- "otherRawBytes": 226185,+ "largestAssetRawBytes": 751904,+ "otherRawBytes": 227469,"requestCount": 96,- "scriptRawBytes": 4718489,+ "scriptRawBytes": 4760595,"scriptRequestCount": 91,- "totalRawBytes": 5014895+ "totalRawBytes": 5058285},"routeReadyMedianMs": 1042.5,"scriptSourceOwnerSet": "editor-canvas-static",@@ -257,12 +257,12 @@"cssRawBytes": 17572,"fontRawBytes": 23664,"imageRawBytes": 44398,- "largestAssetRawBytes": 752413,- "otherRawBytes": 226185,+ "largestAssetRawBytes": 751904,+ "otherRawBytes": 227469,"requestCount": 94,- "scriptRawBytes": 4644510,+ "scriptRawBytes": 4690653,"scriptRequestCount": 88,- "totalRawBytes": 4956329+ "totalRawBytes": 5003756},"routeReadyMedianMs": 1093.0999999046326,"scriptSourceOwnerSet": "editor-workflow-static",@@ -295,12 +295,12 @@"cssRawBytes": 17572,"fontRawBytes": 23664,"imageRawBytes": 44398,- "largestAssetRawBytes": 752413,- "otherRawBytes": 226185,+ "largestAssetRawBytes": 751904,+ "otherRawBytes": 227469,"requestCount": 94,- "scriptRawBytes": 4644510,+ "scriptRawBytes": 4690653,"scriptRequestCount": 88,- "totalRawBytes": 4956329+ "totalRawBytes": 5003756},"routeReadyMedianMs": 1105.0999999046326,"scriptSourceOwnerSet": "editor-workflow-static",@@ -333,12 +333,12 @@"cssRawBytes": 2159,"fontRawBytes": 23664,"imageRawBytes": 44398,- "largestAssetRawBytes": 752413,- "otherRawBytes": 226185,+ "largestAssetRawBytes": 751904,+ "otherRawBytes": 227469,"requestCount": 87,- "scriptRawBytes": 4199867,+ "scriptRawBytes": 4238288,"scriptRequestCount": 82,- "totalRawBytes": 4496273+ "totalRawBytes": 4535978},"routeReadyMedianMs": 1324.5,"scriptSourceOwnerSet": "editor-minimal-static",@@ -371,12 +371,12 @@"cssRawBytes": 2159,"fontRawBytes": 23664,"imageRawBytes": 44398,- "largestAssetRawBytes": 752413,- "otherRawBytes": 226185,+ "largestAssetRawBytes": 751904,+ "otherRawBytes": 227469,"requestCount": 87,- "scriptRawBytes": 4199867,+ "scriptRawBytes": 4238288,"scriptRequestCount": 82,- "totalRawBytes": 4496273+ "totalRawBytes": 4535978},"routeReadyMedianMs": 1301.5,"scriptSourceOwnerSet": "editor-minimal-static",