How textailes/mulan works
MulAn is a single-user multispectral image web app: users convert ordered BMP channels to TIFF, upload and inspect TIFF channels, then create and export semantic masks. The React pages call Flask HTTP adapters; services perform conversion, preview generation, and mask editing, backed by UUID-scoped filesystem resources. The graph preserves the documented workflow and annotation/history/export capabilities. Several API and service excerpts are partial, so unsampled operations are linked only where README or indexed references support the relationship.
Main entry points: App.tsx App routes · client.ts API client · AnnotatorPage.tsx Mask annotator · ViewerPage.tsx TIFF viewer
Components 17
Web interface
- App routes
frontend/src/App.tsx - BMP converter
frontend/src/pages/ConvertPage.tsx - Conversion result
frontend/src/pages/ConvertResultPage.tsx - TIFF viewer
frontend/src/pages/ViewerPage.tsx - Mask annotator
frontend/src/pages/AnnotatorPage.tsx - Image controls
frontend/src/components/ImageControls.tsx - Upload dropzone
frontend/src/components/UploadDropzone.tsx - Annotation tools
frontend/src/components/annotationTools.ts - Unsaved state
frontend/src/context/UnsavedContext.tsx - API client
frontend/src/api/client.ts
HTTP API
- Public API
backend/mulan/api/public.py - Internal API
backend/mulan/api/internal.py
Image processing
- BMP conversion
backend/mulan/services/conversion.py - Image service
backend/mulan/services/images.py - Annotation service
backend/mulan/services/annotations.py
Resource storage
- Filesystem store
backend/mulan/storage/filesystem.py
Other components
- User
Connections 26
- User → App routes: uses
README.md - App routes → BMP converter: routes to
frontend/src/App.tsx - App routes → Conversion result: routes to
frontend/src/App.tsx - App routes → TIFF viewer: routes to
frontend/src/App.tsx - App routes → Mask annotator: routes to
frontend/src/App.tsx - BMP converter → Upload dropzone: renders
frontend/src/pages/ConvertPage.tsx - TIFF viewer → Image controls: renders
frontend/src/pages/ViewerPage.tsx - TIFF viewer → Upload dropzone: renders
frontend/src/pages/ViewerPage.tsx - Mask annotator → Image controls: renders
frontend/src/pages/AnnotatorPage.tsx - Mask annotator → Upload dropzone: renders
frontend/src/pages/AnnotatorPage.tsx - Mask annotator → Annotation tools: uses
frontend/src/pages/AnnotatorPage.tsx - App routes → Unsaved state: provides state
frontend/src/App.tsx - BMP converter → API client: requests conversion
frontend/src/pages/ConvertPage.tsx - Conversion result → API client: requests result
frontend/src/pages/ConvertResultPage.tsx - TIFF viewer → API client: requests image
frontend/src/pages/ViewerPage.tsx - Mask annotator → API client: requests annotation
frontend/src/pages/AnnotatorPage.tsx - API client → Public API: HTTP requests
frontend/src/api/client.ts - API client → Internal API: HTTP requests
frontend/src/api/client.ts - Public API → Image service: calls
backend/mulan/api/public.py - Public API → BMP conversion: calls
backend/mulan/api/public.py - Public API → Annotation service: calls
backend/mulan/api/public.py - Internal API → Annotation service: calls
backend/mulan/api/internal.py - BMP conversion → Filesystem store: stores resources
- Image service → Filesystem store: reads and writes
backend/mulan/services/images.py - Annotation service → Image service: uses image service
backend/mulan/services/annotations.py - Annotation service → Filesystem store: reads and writes
backend/mulan/services/annotations.py