Renaming of methods' Problems
See original GitHub issueIn the next release of SimPEG we are renaming many of the base properties to be more in line with pythonic conventions, pep8, etc., and we are also refactoring to get rid of SimPEG’s Problem and replacing it with Simulation (which moves the forward operations from a Survey object that has been paired with a Problem to just a Simulation). As part of this, I’d also like to update the names for each method’s problems, to have a consistent convention across SimPEG.
Currently
For example in FDEM and TDEM, the names are
Problem3D_EProblem3D_BProblem3D_HProblem3D_j
In natural source em:
Problem1D_ePrimSecProblem3D_ePrimSec
In the static methods IP, and DC, they are
Problem2D_CCProblem2D_NProblem3D_CCProblem3D_N
The simulations in the potential field methods are currently
MagneticIntegralProblem3D_DiffSecondaryGravityIntegralProblem3D_Diff
In VRM
Problem_LinearProblem_LogUniform
And the others:
RichardsProblemStraightRayProblem
As you can see, the convention in naming is certainly not consistent, and we should make a decision moving forward of a good convention that incorporates the Simulation name possibly. Some things we might want to keep are, distinguishing between dimensionality of a simulation, possibly being able to use autocomplete within each package to find the simulations (a.k.a. they would all start with Simulation), being descriptive with the names, etc. We would like to keep pep8 conventions for class names. Keep in mind that the method names would already be a part of the path to the Simulation class.
Mostly try to think about how suggestions would propagate, as some things might get quite long. For example I’ll put out three possible formats:
Simulation(Dimension)(ShortDescription), Simulation(Dimension)(LongDescription), (LongDescription)Simulation(Dimension).
For Example
-
Problem3D_E→Simulation3DEorSimulation3DElectricFieldorElectricFieldSimulation3D. -
Problem3D_B→Simulation3DBorSimulation3DMagneticFluxDensityorMagneticFluxDensitySimulation3D -
Problem3D_j→Simulation3DJorSimulation3DCurrentDensityorCurrentDensity3DSimulationnote here, shouldjbe capitalized or not? -
Problem3D_CC→Simulation3DCCorSimulation3DCellCenteredorCellCenteredSimulation3D. -
MagneticIntegral→Simulation3DIntorSimulation3DIntegralorIntegralSimulation3D
Issue Analytics
- State:
- Created 4 years ago
- Comments:6 (6 by maintainers)

Top Related StackOverflow Question
Just to keep this updated, we had a nice discussion on this at the last SimPEG meeting (Feb. 26th, 2020) and decided on a general format of Simulation(Dimension)(LongDescription).
With two major thoughts, the first being that a longer description allows an unfamiliar user to better understand what it is. The second, that you can always do something in your own code such as
from SimPEG.electromagnetics.frequeny_domain import Simulation3DElectricField as Simso it doesn’t need to be typed out every time.Thanks for getting this going @jcapriot! I agree with the general naming convention of
Simulation(Dimension)(ShortDescription). This keeps the names grouped together when tab-completing, and stays fairly compact.So my vote is with the pattern
Problem3D_E→Simulation3DEProblem3D_B→Simulation3DBProblem3D_j→Simulation3DJProblem3D_CC→Simulation3DCCMagneticIntegral→Simulation3DIntegral(here I thinkIntegralis worth spelling out b/cIntmaps toIntegerin so many other contexts)for visuals, I am also fine with lower-casing the
E,CCetc