SmoldynFileWriter sets no boxsize: models starting with few or no particles get one virtual box (N×M surface checks)
Los mantenedores suelen responder en 1 día
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 3/5
- Tiempo estimado
- 1-2 días
- Aptitud para principiantes
- 66/100
- Tipo de issue
- Nueva funcionalidad
- Claridad
- Bien especificado
- Estado de actividad
- Activo
- Stack tecnológico
- java
Línea de trabajo
Start at vcell-core/src/main/java/org/vcell/solver/smoldyn/SmoldynFileWriter.java, where the .smoldynInput file is assembled, and locate where box statements could be emitted alongside molperbox. Determine what mesh-spacing or diffusion-length information is available at that point (the writer already has geometry/membrane panel data) to compute a boxsize. Done means a model starting with zero or few particles produces a .smoldynInput containing an explicit boxsize, verified by running such a model and checking Smoldyn's log reports more than 1 virtual box.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Summary
SmoldynFileWriter writes neither boxsize nor molperbox. Smoldyn then sizes its virtual boxes from the initial molecule count.
In vcell-fvsolver's Smoldyn 2.38, boxesupdatelists uses mpbox = 4 or 5 and molcount(...) (L638). The boxes per side are ceil(L·(n / mpbox / V)^(1/dim)). A model that starts with no particles, e.g. particles created by a reaction, therefore gets 0 → clamped to 1 box per side, so a single box. Few initial particles give a few huge boxes.
With one box, every molecule is tested against every surface panel every time step: N molecules × M triangles. VCell meshes membranes finely (9,516 triangles for a 4 µm sphere on a 37³ mesh), so this can dominate run time as particles accumulate.
Evidence
- Native: confirmed from the code above, not from a timed run. The
.smoldynInputVCell generates has no box statements, and vcell-fvsolver's log does not print Smoldyn's box parameters. - The same Smoldyn logic, measured in a co-simulation (upstream Smoldyn with the VCell hybrid extensions; 806 membrane triangles; exchange model starting with 0 particles):
- Smoldyn reported 1 virtual box. Profiling put about 95% of the time in
checksurfaces → lineXpanel/panelside. - Setting
boxsizeexplicitly (two grid spacings) cut the cost 10×, from 4.55 to 0.45 wall s per simulated s. - A model starting with 20,000 particles automatically got 18³ boxes and did not show the problem.
- Details: DESIGN.md §11.
- Smoldyn reported 1 virtual box. Profiling put about 95% of the time in
Suggested fix
Write boxsize explicitly, e.g. a small multiple of the mesh spacing (or the diffusion length per step), instead of relying on molperbox and the initial count.
Related, and already in VCell: the highResVolumeSamples map accelerates compartment tests (posincompart). Box sizing is the corresponding acceleration for collision checks during diffusion.
Found while benchmarking the embedded hybrid against a process-bigraph co-simulation (vivarium-collective/viva-pde-particle).
- Lenguaje dominante
- Java
- Estrellas
- 140
- Forks
- 35
- Merge medio
- 17 h 39 min
- PR fusionados (30 d)
- 19
Preparar el entorno
- Incluye un Dockerfile o un archivo de Docker Compose
- Sin plantilla de pull request
- Leer la guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de virtualcell/vcell
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
virtualcell/vcell#2193 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
Accessibility Requirement Java-based User Interface
Dificultad 2/5 1-3 horas Aptitud para principiantes 74/100
virtualcell/vcell#2138 ·
Los mantenedores suelen responder en 1 día
-
Accessibility Requirement Java-based
Dificultad 2/5 1-3 horas Aptitud para principiantes 80/100
virtualcell/vcell#2137 ·
Los mantenedores suelen responder en 1 día
-
Accessibility Requirement User Interface
Dificultad 2/5 1-3 horas Aptitud para principiantes 88/100
virtualcell/vcell#2135 ·
Los mantenedores suelen responder en 1 día
-
Accessibility Requirement Java-based User Interface
Dificultad 2/5 1-3 horas Aptitud para principiantes 84/100
virtualcell/vcell#2134 ·
Los mantenedores suelen responder en 1 día
Todos los issues de virtualcell/vcell
Issues similares
-
Type: Bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 76/100
Los mantenedores suelen responder en 1 día
-
MCP add-on: JSON responses with non-ASCII characters are truncated (wrong Content-Length)Posiblemente ocupada @dhanushbs10 la tomó hoy. Abiertoadd-on bug in:mcp
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
Los mantenedores suelen responder en 1 día
-
vaadin-map
Dificultad 2/5 1-3 horas Aptitud para principiantes 70/100
vaadin/flow-components#10586 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 63/100
wpilibsuite/SystemcoreTesting#446 ·
Los mantenedores suelen responder en 1 día
-
frontend quality-assurance
Dificultad 2/5 1-3 horas Aptitud para principiantes 64/100
Paul-Austin-Oswego-CSC480-HCI521/gift-app#212 ·
Los mantenedores suelen responder en 1 día