Simulation (Surgical Simulation from a Photograph)
How a physician can show a patient the anticipated result of plastic surgery on the patient's own photograph: three ways of working in the "Simulation" section, the control point editor, "before / after" comparison, and export.
What it is and who has access
The "Simulation" section is a physician's consultation tool: you upload a patient photograph and demonstrate how the shape of the nose, chin, breast, and so on may change after surgery.
- Who uses it: the physician only. The patient does not have access to the section and does not create the "after" image.
- Where: the physician's outpatient clinic workspace (physician menu "Clinic" → "My Patients"), then the "Simulation" item in the left-hand menu; address
/dp/simulation. Help for the section is at/dp/simulation/help(this same text). - Important: any simulation is an illustration of the surgical plan, not a guarantee of the result. The outcome depends on anatomy, tissue quality, and healing. This is exactly how it should be presented to the patient.
Three ways of working
The /dp/simulation page offers three cards. These are not an "old and new version," but different approaches.
Option 1 — "Single image" (/dp/simulation/face)
A plan based on a single photograph: facial anatomical landmarks, measurements, and manual shape deformation using control points. The result is reproducible: the same plan always yields the same image. Suitable for rhinoplasty, mentoplasty, and symmetry assessment.
Option 2 — "Series of views" (/dp/simulation/breast)
Breast plans based on several images of the same patient (frontal, profiles, three-quarter, inferior), grouped by patient. Deformation is likewise performed with control points, and the result is reproducible.
Option 3 — "AI from photograph" (/dp/simulation/ai)
A neural network redraws the image according to the edits you select and the description you provide. This is a rapid "preview" for discussion with the patient: a repeat run produces a different image, and no measurements can be taken from it. It operates through a surgical case and consumes the monthly AI simulation quota. Details are provided below, in the "AI from photograph" section, and in /docs/surgery.
Option 1: plan from a single image
Creating a plan
- Open
/dp/simulation/face→ "New plan". - Step 1 of 2: drag a photograph in or click the upload area. Formats JPG, PNG, WebP, up to 20 MB, with no side smaller than 200 px. HEIC (the native iPhone format) is not accepted — save the photograph as JPG.
- Step 2 of 2: the plan name (up to 200 characters) and, optionally, a patient identifier (chart number, initials). Click "Create plan".
- The editor opens.
Very large photographs are downscaled by the server to 4000 px on the longer side. The plan name and patient identifier are stored in encrypted form.
Plan list
- Search by name or patient; sorting: "Newest first", "Oldest first", "By name".
- Each plan has a menu: "Open", "Duplicate", "Delete".
- "Duplicate" creates a copy with the same photograph and all control points — convenient for variants (conservative / moderate / pronounced).
- "Delete" asks for confirmation. The plan is archived, the image is deleted irreversibly, and the action cannot be undone.
Facial anatomical landmarks
When a plan is opened, the system automatically detects the face and places anatomical landmarks (facial contour, nose, lips, eyes, eyebrows). The "Anatomical landmarks" panel displays the status: "Detected", "Error", and so on.
- "Re-detect" — run detection again.
- Landmark groups can be shown or hidden individually.
- If there are several faces in the photograph, select the one you need.
- If automatic detection fails (profile view, poor lighting, non-standard angle), click "Mark manually": a step-by-step wizard will prompt you to place the landmarks, which takes less than a minute. To repeat, use "Mark again".
Measurements
The "Measurements" panel appears once landmarks have been detected:
- Nasofrontal angle — the angle between the line of the forehead and the nasal dorsum; normal range 115°–135°.
- Nasal tip projection (Goode) — the ratio of tip length to nasal height.
- Alar base width — without calibration this is displayed in relative units, not millimeters.
Each measurement can be shown or hidden on the image.
Control points and deformation
Each control point consists of:
- a square — the original center of deformation;
- a blue circle — the point to which the tissue is "pulled"; this is what you drag;
- a dashed line between them — the direction and magnitude of displacement;
- a dashed circle — the zone of influence; beyond it the image does not change.
How to work:
- Enable "Add point" mode (the "+•" icon on the toolbar).
- Click the anatomical landmark you wish to modify — a control point appears.
- Return to selection mode (arrow or Esc) and drag the blue circle. The photograph changes immediately.
- Select a point to configure the following in the "Deformation point" panel:
- Effective radius — from 1 to 50% of the photograph size; a new point is assigned 5%;
- Strength — from −1 to +1; a new point is assigned 0.5; a negative strength produces the opposite effect.
- Alt + dragging the square moves the center of the point.
Up to 500 control points are allowed per plan.
The "Actions" block: "Step back", "Remove manual points" (remove manually placed landmarks while preserving the result achieved), "Reset all" (return to the original photograph — irreversible).
Techniques that yield a refined result
- A small radius (2–4%) — for a focal correction, such as a dorsal hump: adjacent areas are barely displaced.
- A chain of points along the nasal dorsum or the jawline — to straighten the line rather than "push in" a circle.
- Anchor points — place points around the area being corrected and do not move them: they hold the adjacent tissues (lip, cheeks, background) in place.
- Do not combine a large radius with a large displacement — waves will appear in the background and hair.
- Work at 100% zoom or greater — points are placed more precisely.
- Maintain symmetry manually: there is no mirror mode.
Toolbar and keyboard shortcuts
- Selection mode, add-point mode, undo / redo, zoom "−" / "+", "Fit", "Reset (100%)", save indicator.
- Mouse wheel — zoom toward the cursor; dragging the background — pan.
Ctrl+Z— undo;Ctrl+Shift+ZorCtrl+Y— redo.DeleteorBackspace— remove the selected point.Esc— clear the selection and return to selection mode.
Autosave
Changes are saved automatically 2 seconds after the last action. Indicator states: "Saving…", "Saved", "Save error" (usually no internet connection or an expired session — refresh the page).
"Before / After" and export
The "Before / After" tab is intended for presentation to the patient: the image is divided by a slider, with "Before" on the left and "After" on the right.
The "Export" panel:
- What: "Before surgery (original)", "After surgery (with deformation)", "Side by side: before and after".
- Format: JPG or PNG; for JPG, quality from 40 to 100%.
- "Download" — the file is saved to your computer. Export is performed at full resolution: wait until "Preparing full resolution…" has completed.
Downloaded files are ordinary images without encryption; store them in accordance with your clinic's policies.
Option 2: series of views (breast)
/dp/simulation/breast→ "New plan".- Step 1 of 3 — photograph (JPEG, PNG, WebP, up to 20 MB).
- Step 2 of 3 — view: frontal, left or right profile, left or right three-quarter, inferior.
- Step 3 of 3 — plan label and patient (optional).
The list is grouped by patient: you can see how many views a patient has and whether each has been marked up. Search is by patient or label.
In the editor:
- procedure type: augmentation, reduction, mastopexy;
- deformation points: click on the photograph to add, drag the blue point for deformation, drag the green one to reposition, click a point for radius and strength, mouse wheel for radius, Shift+click to delete;
- "Fine tuning": overall strength, radius, lateral and vertical offset; "Reset" restores the original values.
"Before / After" becomes available once there is at least one point. Comparison modes: slider, side by side, toggle, animation. Export: comparison as PNG or JPG, "before" only or "after" only (PNG), a 3-page PDF report.
Option 3: AI from photograph
The /dp/simulation/ai page works in three steps.
- Case. Select a surgical case or create a new one: procedure type and a note (optional). A case created here is anonymous — not linked to a patient chart. A linked case is created in the surgery section (
/docs/surgery). - Photograph. First select the view (frontal, profile, three-quarter, other), then the PNG, JPEG, or WebP file. The view matters: a dorsal hump and the profile line are visible only laterally; a request to "remove the hump" applied to a frontal image will return almost the same frame.
- Edit. Select the image, the area to be corrected, mark the preset edits ("Slightly", "Noticeably", "Markedly") and/or describe the change in words in any language. Check the box "I understand that the simulation does not guarantee the result" and click "Generate".
There is no need to brush-select an area — the neural network locates the face and the relevant zone on its own. It does not act on values in degrees and millimeters: these are converted into "slightly" or "noticeably".
A single variant takes about a minute to prepare. The "Simulation history" shows what was submitted to the neural network; a variant can be selected, enlarged, downloaded, or deleted. If the model barely altered the image, this is flagged and is not counted against the quota.
The AI simulation quota covers a rolling 30 days and counts only successful runs: Doctor Pro — 100, Doctor Super — 200, Doctor Pro trial period — 25. AI is disabled on Doctor Free. When 2 or fewer remain, an offer to purchase an additional package appears: 25 simulations for $39 or 100 for $129; the package is consumed after the monthly quota. Plans are described at /docs/plans.
"Text-based request" prototype
A prototype is available at /dp/simulation/plan: the physician describes the operation in words, the system converts the text into a rhinoplasty plan (profile view) with parameters in millimeters and degrees, and the plan is then adjusted with sliders and checked against normative values. It has been removed from the section's showcase; only profile-view rhinoplasty is supported, and text parsing is limited to no more than 20 requests per minute.
Photograph requirements
- No selfies and no front-facing camera: a wide-angle lens distorts the nose and chin. Shoot from 1.5 m or farther.
- Even frontal lighting, without harsh shadows; a plain light background.
- Neutral face: lips closed, gaze directed at the camera. Hair pulled back, jewelry removed.
- Option 1 requires one image per plan; different views mean different plans. In Option 2, views are grouped under a single patient.
- For AI from photograph, images larger than 1000 px produce more confident edits.
A poor photograph creates false expectations — it is better to retake it.
Confidentiality
- Plans are visible only to the physician who created them.
- The plan name and patient identifier are stored encrypted.
- Before uploading a photograph, obtain the patient's consent to the processing of their image.
- General data protection rules are described at
/docs/privacy.
If something is not working
- The photograph will not upload — the format is not JPG/PNG/WebP (HEIC is not accepted), the file exceeds 20 MB, is smaller than 200 px, or is corrupted.
- An empty canvas after creating a plan — a newly uploaded photograph may become available after a few seconds; the page retries loading on its own. If that does not help, refresh the page.
- Landmarks are not detected automatically — use "Mark manually".
- The photograph does not change when dragging — close extra tabs and refresh the page; on a low-powered device with a large number of points, the deformation is computed more slowly.
- A red save indicator — check your internet connection and refresh the page; changes up to the last 2 seconds have been saved.
- AI from photograph "changed nothing" — check the view of the image and try again or rephrase; such an attempt does not consume the quota.
Frequently asked questions
Where do I find the simulation tool? The physician menu "Clinic" → "My Patients" opens the outpatient clinic workspace; the "Simulation" item is in the left-hand menu there. The direct address is /dp/simulation.
Can the patient view the "after" image independently? No. The section is for the physician only; show the result during the visit or send the exported file.
What does it cost? Options 1 and 2 (control points) require no separate payment. "AI from photograph" consumes the plan's AI simulation quota: Doctor Pro — 100 per 30 days, Doctor Super — 200, trial period — 25; packages of 25 for $39 and 100 for $129. AI simulations are not available on Doctor Free.
How does "Single image" differ from "AI from photograph"? In "Single image" you move the control points yourself; the result is precise and reproducible, and measurements are available. "AI from photograph" redraws the image with a neural network: fast and illustrative, but different on each run and without measurements.
Can I create several variants of the same operation? Yes: "Duplicate" the plan and modify the copy. In AI from photograph, simply run the generation again.
Why are the measurements not in millimeters? Without calibration, alar base width is displayed in relative units; angles and ratios do not depend on calibration.
How many points can I place? Up to 500 control points per plan. Usually 10–25 are sufficient.
Can a deleted plan be restored? No, the photograph is deleted irreversibly. Make a copy with "Duplicate" before experimenting.
Is HEIC from iPhone supported? Not in Options 1 and 2 — save the photograph as JPG. AI from photograph accepts PNG, JPEG, and WebP.
Why did the AI not remove the dorsal hump? Most likely a frontal image was selected: a hump is visible only in profile. Upload a profile image and specify its view.
How do I present the result during a consultation? Open the "Before / After" tab on a large screen and let the patient move the slider, then export "Side by side: before and after" for the patient chart.
<!-- translated-from-ru: eba2a4a771733998e4c739c6f6ec7fb1733f36a7 -->