PyAutoFit
PyAutoFit copied to clipboard
_ used to denote private in the model
The model uses recursion extensively to self-inspect, determining dimensionality and populating priors for example. However, some attributes associated with the model are there for its function as oppose to representing objects that should be manipulated and instantiated. To reduce occurrence of bugs a distinction should be made between model attributes that serve some functional purpose and those that are actually being modelled.
Using the _ convention to indicate a private attribute and ignoring any attribute that starts with _ during recursion should suffice. This would apply to any model object (abstract, collection, prior etc.) as well as promises and priors.