pisces.extensions.simulation.core.initial_conditions.InitialConditions.remove_particles_from_model#
- InitialConditions.remove_particles_from_model(model_name: str, delete_particle_file: bool = True)[source]#
Detach and optionally delete the particle dataset associated with a specific model.
This method:
Validates that the target model exists in the configuration.
Checks if a particle file is associated with the model.
Optionally deletes the particle file from disk.
Updates the configuration to remove the particle file reference.
- Parameters:
- Raises:
KeyError – If no model with the given
model_name
exists in the configuration.ValueError – If no particles are associated with the specified model.