|
YAC 3.18.0
Yet Another Coupler
|
Defines the interface for interpolation method configuration "base class" in YAC. More...
#include "interp_method.h"

Go to the source code of this file.
Defines the interface for interpolation method configuration "base class" in YAC.
This header provides the public API for managing interpolation method configurations, including copying, comparison, packing/unpacking for MPI communication, and generating interpolation method instances from configurations.
The actual structure of yac_interp_method_config is opaque to users and is managed internally by the YAC library. Users interact with it through the provided interface functions.
The purpose of an interpolation method configuration class is to enable the exchange and comparison of method configurations between processes during initialization (for example, when a configuration file is read by only a subset of processes). Interpolation stack configurations (see interp_stack_config.h) hold abstract representations of interpolation method configurations, without requiring knowledge of the specifics of each individual method. When an actual interpolation method instance is needed, it can be generated from the abstract configuration using the generic interface.
Concrete constructors for interpolation method configurations can be found in the method-specific header files (e.g., yac_interp_method_config_default_avg_new in interp_method_avg.h).
Definition in file interp_method_config.h.
| size_t yac_interp_method_config_append_list_element | ( | struct yac_interp_method_config * | config, |
| const char * | path ) |
Append a new default element to a list parameter identified by a dot-separated path. The new element's sub-parameters can then be set using the scalar setters with a path of the form "listname.N.subparam" where N is the returned index.
| config | Pointer to config (must not be NULL). |
| path | Dot-separated path to the list parameter. |
Definition at line 507 of file interp_method_config.c.


| int yac_interp_method_config_compare | ( | struct yac_interp_method_config const * | a, |
| struct yac_interp_method_config const * | b ) |
Compare two yac_interp_method_config instances.
| a | First config. |
| b | Second config. |
Definition at line 98 of file interp_method_config.c.


| struct yac_interp_method_config * yac_interp_method_config_copy | ( | const struct yac_interp_method_config * | config | ) |
Copy an yac_interp_method_config instance.
| config | Pointer to config to copy. |
Definition at line 81 of file interp_method_config.c.

| struct yac_interp_method_config * yac_interp_method_config_default_from_name_new | ( | char const * | method_name | ) |
Create an interpolation method configuration with default values by name.
| method_name | Interpolation method identifier string. |
Definition at line 205 of file interp_method_config.c.


| void yac_interp_method_config_delete | ( | struct yac_interp_method_config * | config | ) |
Delete (deallocate) an yac_interp_method_config instance.
| config | Pointer to config to delete. |
Definition at line 74 of file interp_method_config.c.

| struct interp_method * yac_interp_method_config_generate | ( | struct yac_interp_method_config const * | config | ) |
Generate interp_method instance from config.
| config | Pointer to config. |
Definition at line 244 of file interp_method_config.c.

| size_t yac_interp_method_config_get_list_size | ( | struct yac_interp_method_config const * | config, |
| const char * | path ) |
Get the number of elements in a list parameter identified by a dot-separated path.
| config | Pointer to config (must not be NULL). |
| path | Dot-separated path to the list parameter. |
Definition at line 484 of file interp_method_config.c.


| size_t yac_interp_method_config_get_pack_size | ( | struct yac_interp_method_config const * | config, |
| MPI_Comm | comm ) |
Get the size (in bytes) required to pack this config with MPI_Pack.
| config | Pointer to config. |
| comm | MPI communicator (for MPI_Pack_size). |
Definition at line 121 of file interp_method_config.c.


| struct yac_param * yac_interp_method_config_get_param | ( | struct yac_interp_method_config const * | config | ) |
Get a handle to the parameter tree for this config.
| config | Pointer to config. |
Definition at line 195 of file interp_method_config.c.

| double yac_interp_method_config_get_param_dble | ( | struct yac_interp_method_config const * | config, |
| const char * | path ) |
Get the double value of a parameter identified by a dot-separated path.
| config | Pointer to config (must not be NULL). |
| path | Dot-separated path to the target parameter. |
Definition at line 417 of file interp_method_config.c.


| int yac_interp_method_config_get_param_int | ( | struct yac_interp_method_config const * | config, |
| const char * | path ) |
Get the integer value of a parameter identified by a dot-separated path.
| config | Pointer to config (must not be NULL). |
| path | Dot-separated path to the target parameter. |
Definition at line 394 of file interp_method_config.c.


| char * yac_interp_method_config_get_param_str | ( | struct yac_interp_method_config const * | config, |
| const char * | path ) |
Get a copy of the string representation of a parameter identified by a dot-separated path.
| config | Pointer to config (must not be NULL). |
| path | Dot-separated path to the target parameter. |
Definition at line 440 of file interp_method_config.c.


| enum yac_interpolation_list yac_interp_method_config_get_type | ( | struct yac_interp_method_config const * | config | ) |
Get the type identifier for this config.
| config | Pointer to config. |
Definition at line 183 of file interp_method_config.c.

| void yac_interp_method_config_pack | ( | struct yac_interp_method_config const * | config, |
| void * | buffer, | ||
| int | buffer_size, | ||
| int * | position, | ||
| MPI_Comm | comm ) |
Pack config into MPI buffer.
| config | Pointer to config. |
| buffer | Buffer to pack into. |
| buffer_size | Size of buffer. |
| position | Position in buffer (as in MPI_Pack). |
| comm | MPI communicator. |
Definition at line 133 of file interp_method_config.c.


| void yac_interp_method_config_set_param_dble | ( | struct yac_interp_method_config * | config, |
| const char * | path, | ||
| double | value ) |
Set a parameter of the config identified by a dot-separated path to a double value.
| config | Pointer to config (must not be NULL). |
| path | Dot-separated path to the target parameter. |
| value | Double value to set. |
Definition at line 373 of file interp_method_config.c.


| void yac_interp_method_config_set_param_int | ( | struct yac_interp_method_config * | config, |
| const char * | path, | ||
| int | value ) |
Set a parameter of the config identified by a dot-separated path to an integer value.
| config | Pointer to config (must not be NULL). |
| path | Dot-separated path to the target parameter. |
| value | Integer value to set. |
Definition at line 352 of file interp_method_config.c.


| void yac_interp_method_config_set_param_str | ( | struct yac_interp_method_config * | config, |
| const char * | path, | ||
| const char * | value ) |
Set a parameter of the config identified by a dot-separated path to a string value (parsed according to the parameter's type).
| config | Pointer to config (must not be NULL). |
| path | Dot-separated path to the target parameter, e.g. "n" or "search_distance.fixed". |
| value | String representation of the new value. |
Definition at line 330 of file interp_method_config.c.


| struct yac_interp_method_config * yac_interp_method_config_unpack | ( | void * | buffer, |
| int | buffer_size, | ||
| int * | position, | ||
| MPI_Comm | comm ) |
Unpack config from MPI buffer.
| buffer | Buffer to unpack from. |
| buffer_size | Size of buffer. |
| position | Position in buffer (as in MPI_Unpack). |
| comm | MPI communicator. |
Definition at line 148 of file interp_method_config.c.
