cluster_collections.ProtoCluster.__init__#
- ProtoCluster.__init__(profiles, parameters, names, load_method)[source]#
Loads the
ProtoClusterinstance.- Parameters:
profiles (
dictofstr:callableordictofstr:str) –A dictionary containing the profile definitions for the cluster initialization. There are two available options for the formatting of each element in this argument:
If the dictionary value is a
strtype, then it is assumed to be a pre-defined profile already defined in thecluster_generator.radial_profilesmodule. If a corresponding built-in profile cannot be found, an error will be raised.If the dictionary value is a
callableinstance of any kind, it is assumed to be a user defined function (either explicit or lambda). It will be wrapped in acluster_generator.radial_profiles.RadialProfileinstance during initialization.
parameters (
dictofstr:list) –A dictionary containing the parameters for the profiles. For each profile in
profiles, there should be a corresponding key-value pair in theparametersargument containing alistwith the values of each of the necessary parameters for the specific cluster being modeled.Note
If the type of the elements in the list is
floatorint, then it will be assumed that these parameters are already following the unit conventions of the CGP. If there is any doubt, we recommend passing the parameters asunyt.array.unyt_quantityinstances instead. These will be processed to the correct units before proceeding.load_method (
str) – Theload_methodshould correspond to the analogous class method onmodel.ClusterModelfor loading the full model instance. Typically, these should be something likefrom_dens_and_temporfrom_dens_and_tden.