simudo.gui.panels package¶
Submodules¶
simudo.gui.panels.bands module¶
Simudo GUI — Bands panel.
simudo.gui.panels.bcs module¶
Simudo GUI — Boundary Conditions panel.
- Shows left and right contact cards. Each card has:
role (Select: swept / reference)
per-band BC (RadioButtonGroup: ohmic / zero_current / SRV)
when SRV selected: value + unit inputs for surface recombination velocity
simudo.gui.panels.layers module¶
Simudo GUI — Layers panel.
Uses the “update in place” pattern: persistent pn.Column/.pane objects whose .objects / .object attributes are mutated directly, giving immediate DOM updates without relying on Panel’s reactive parameter machinery.
simudo.gui.panels.mat_ast module¶
AST-based introspection of Python Material subclass files.
Imports nothing from dolfin/simudo so it runs on the host machine without the simulation environment installed.
- class simudo.gui.panels.mat_ast.ClassInfo(class_name: 'str', file_path: 'str', material_name: 'Optional[str]' = None, properties: 'List[PropertyInfo]' = <factory>)[source]¶
Bases:
object- class_name: str¶
- property computed_properties: List[PropertyInfo]¶
- property copyable_properties: List[PropertyInfo]¶
- file_path: str¶
- material_name: str | None = None¶
- properties: List[PropertyInfo]¶
- class simudo.gui.panels.mat_ast.PropertyInfo(key: 'str', display: 'str', copyable: 'bool', value: 'Optional[float]' = None, unit: 'str' = '', is_callable: 'bool' = False, callable_type: 'str' = '')[source]¶
Bases:
object- callable_type: str = ''¶
- copyable: bool¶
- display: str¶
- is_callable: bool = False¶
- key: str¶
- unit: str = ''¶
- value: float | None = None¶
- simudo.gui.panels.mat_ast.extract_classes_from_file(file_path: str) List[ClassInfo][source]¶
Parse a .py file and return a ClassInfo for every material class in it.
Non-material helper classes are skipped — see _is_material_base.
simudo.gui.panels.materials module¶
Simudo GUI — Materials panel.
- Materials supply property defaults at PRIORITY_MATERIAL (lowest). Two kinds:
Inline — key/value/unit pairs stored directly in the YAML.
Library ref —
source: library://ClassName, loaded by the runner.
The panel shows a browseable catalogue of classes found in library directories and a list of project-specific materials.
simudo.gui.panels.opt_fields module¶
Simudo GUI — Optical Fields panel.
- Lists optical fields with add / delete. Each field has:
name (TextInput)
direction (+x / −x radio)
photon_energy (value + unit)
- intensity mode (Explicit | Blackbody)
Explicit → value + unit Blackbody → T_source, concentration, E_min, E_max (∞ checkbox)
simudo.gui.panels.output module¶
Simudo GUI — Output panel.
Sections:
1. Folder selector (editable path + open-in-finder + refresh buttons)
2. J-V plot (Bokeh interactive; linear / log|J| toggle)
3. Band diagram (spatial data via spatial_extractor.py -> dolfin in
container)
- layer schematic linked to band-diagram x-axis (Bokeh shared x_range)
- band plot (Ephi_* solid black, qfl_* dashed coloured)
4. Add-plot dashboards (user-defined lines from any spatial quantity, each
with its own schematic linked via shared x_range)
Design notes:
- Each Bokeh figure is wrapped in a resizable pn.Column card
(CSS resize:vertical). The Bokeh figure inside uses
sizing_mode="stretch_both" so it fills the card.
- Voltage-dropdown changes update the band diagram in-place (pane.object
swap) rather than clearing/appending to a Column, to avoid page-scroll
resets.
- Schematic figures share x_range with their companion data figure so that
pan/zoom on the data figure automatically updates the schematic.
simudo.gui.panels.processes module¶
Simudo GUI — Processes panel.
- Each process has:
name
class (Select — discovered by AST-parsing electro_optical_process.py)
lower-energy band (src_band in YAML)
higher-energy band (dst_band in YAML)
trap_band (conditional — TrapEOPMixin subclasses only)
Include radiative recombination: Yes/No (conditional — optical classes only)
EOP class discovery:
The panel scans electro_optical_process.py at startup using ast.parse() (no
import, no dolfin) to find all concrete subclasses of ElectroOpticalProcess
and determine:
- optical classes: inherit AbsorptionAndRadiativeRecombinationEOPMixin
-> show radiative toggle
- trap classes: inherit TrapEOPMixin
-> show trap band selector
Cross-reference: see those mixin classes in electro_optical_process.py.
- gui_hint attribute:
- Any EOP class may define a class-level string attribute:
gui_hint = “Brief description visible in the GUI.”
The AST extractor reads this at startup and displays it as a styled note below the class selector whenever that class is selected. Classes without gui_hint show no note. This is how per-class usage instructions are added without modifying the GUI code. The hint is plain text, not markup: it is escaped before display, so a placeholder like ‘<name>/alpha_function’ survives.
simudo.gui.panels.simulation module¶
Simudo GUI — Simulation panel.
- Sections:
Simulation mode (4-way Select: Equilibrium / Dark J-V / Illuminated / Illuminated J-V)
Intensity ramp (selfconsistent_optics, step_size — shown when mode includes ramp)
Voltage sweep (values list / linspace helper, selfconsistent_optics, step_size)
Checkpoints (at_end flags, directory)
Resume-from path
Spatially resolved output (xdmf_mesh, spatial_profiles, output folder)
Execution (backend type + settings; collapsed card)
Run button
- On Run: saves project, builds the appropriate RunnerBackend from the execution
profile, launches the runner, and streams stdout into the log panel.
simudo.gui.panels.stub module¶
Placeholder panels for sections not yet implemented.