Skip to content

Feature2: Added image analysis panel#339

Draft
chetanbarakki wants to merge 5 commits into
c2siorg:mainfrom
chetanbarakki:feature2/add-image-analysis-panel
Draft

Feature2: Added image analysis panel#339
chetanbarakki wants to merge 5 commits into
c2siorg:mainfrom
chetanbarakki:feature2/add-image-analysis-panel

Conversation

@chetanbarakki

Copy link
Copy Markdown
Contributor

Description

  • useStepInspection receives the selected StepResult.
  • It reads the latest executionId from pipelineStore.
  • It calls inspectPipelineStep(executionId, blockId).
  • The backend returns full step image,image format and basic analysis stats
  • The hook updates: active step id/index,processed preview image,active step image,active step analysis,loading/error state
  • A basic histogram is rendered on frontend with rgb, luma toggles

Brief summary of the changes. Reference any related issues.

Fixes #39

Type of Change

  • Bug fix
  • New feature
  • Breaking change
  • Documentation update

How Has This Been Tested?

Describe the tests you ran to verify your changes.

  • Existing tests pass
  • New tests added
  • Manual testing

Screenshots (if applicable)

image

Checklist

  • My code follows the project's style guidelines
  • I have performed a self-review
  • I have added/updated documentation as needed
  • My changes generate no new warnings
  • Tests pass locally

@github-actions

Copy link
Copy Markdown

PR Review

Squash

Your PR has 5 commits. Please squash into a single commit.

How to fix

git fetch origin
git rebase -i origin/main   # mark all but first commit as "squash"
git push --force-with-lease

This comment updates automatically on each push.

@ivantha

ivantha commented Jun 2, 2026

Copy link
Copy Markdown
Member

Automated review summary

Triage: enhancement | Recommendation: needs-revision
GSoC scope: overlaps reserved GSoC scope (issue #39, partial)

Findings

  • [major/quality] imagelab-frontend/src/store/pipelineStore.ts:7 New import type { ImageAnalysis, PipelineTimings, StepResult } from "../types/pipeline" is inserted AFTER two top-level const statements (the imageResetListeners / imageLabelSyncListeners Set declarations). An import following non-import statements is a clear style regression and will trip ESLint's import/first rule, so it risks failing npm run lint in CI (the repo lints frontend with ESLint per CLAUDE.md). Move all imports to the top of the file.
  • [minor/quality] imagelab-backend/app/services/pipeline_executor.py:249 Every successful step caches a full-resolution image.copy() in the in-memory _EXECUTION_CACHE (full_images[cache_key]['image'] = image.copy()). For a long pipeline on a large image, multiplied by up to MAX_EXECUTION_CACHE_ENTRIES (25) concurrent executions, this can hold a large amount of decoded image data in process memory. It is bounded by the TTL + LRU eviction and is documented in the README, so it is acceptable, but worth a comment/limit note; consider capping per-execution retained steps or storing encoded bytes instead of raw ndarrays.
  • [nit/test] imagelab-backend/tests/test_pipeline_api.py:453 PR description leaves the entire "How Has This Been Tested?" section and all checklist items unchecked, and no "Type of Change" box is marked, even though the diff does add substantial backend tests (test_pipeline_api.py / test_pipeline_executor.py). Update the description to reflect the added tests and intended change type so reviewers can triage accurately.

PR #339 adds an image analysis panel (Canvas RGB/luma histogram + stats grid) and per-step intermediate previews, backed by a new versioned API (POST /api/v1/pipeline/executions returning thumbnails + execution_id, and a GET .../steps/inspect endpoint returning full-resolution step images and OpenCV-derived analysis with a TTL/LRU in-memory cache). The work is solid and well-tested, but it directly implements goals 1 and 2 of ImageLab's reserved GSoC scope (issue #39) and says "Fixes #39" — this is a partial overlap with fenced GSoC work, so per the repo's label convention it must not be merged as an ordinary community contribution; the maintainer should confirm that the author (the assigned GSoC student, with the coding period already begun) is opening their own reserved scope before proceeding. Code-wise, fix the misplaced import type in pipelineStore.ts that sits after two const statements (likely an ESLint import/first failure in CI), and consider the memory cost of caching a full-resolution copy of every successful step across up to 25 executions.

Generated by /review-prs. A maintainer will follow up.

@ivantha ivantha added enhancement New feature or request needs-revision Reviewed; changes requested before it can land labels Jun 2, 2026
@chetanbarakki

Copy link
Copy Markdown
Contributor Author

I will make the necessary changes along with rendering of histogram in backend (Proxy Analysis), and Histogram Scaling Issues (like logarithm scaling for dark images) and update by this week

@chetanbarakki chetanbarakki marked this pull request as draft June 2, 2026 17:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request needs-revision Reviewed; changes requested before it can land

Projects

None yet

Development

Successfully merging this pull request may close these issues.

GSoC 2026 — ImageLab: Interactive Learning Mode

2 participants