1.2.3. Field Grouping
[System]
The following APIs are used for field group management. The user can create a group of fields and perform an operation on a group of fields at once.
Functions
- dcgmReturn_t dcgmFieldGroupCreate ( dcgmHandle_t dcgmHandle, int numFieldIds, unsigned short* fieldIds, char* fieldGroupName, dcgmFieldGrp_t* dcgmFieldGroupId )
- dcgmReturn_t dcgmFieldGroupDestroy ( dcgmHandle_t dcgmHandle, dcgmFieldGrp_t dcgmFieldGroupId )
- dcgmReturn_t dcgmFieldGroupGetAll ( dcgmHandle_t dcgmHandle, dcgmAllFieldGroup_t* allGroupInfo )
- dcgmReturn_t dcgmFieldGroupGetInfo ( dcgmHandle_t dcgmHandle, dcgmFieldGroupInfo_t* fieldGroupInfo )
Functions
- dcgmReturn_t dcgmFieldGroupCreate ( dcgmHandle_t dcgmHandle, int numFieldIds, unsigned short* fieldIds, char* fieldGroupName, dcgmFieldGrp_t* dcgmFieldGroupId )
-
Parameters
- dcgmHandle
- IN: DCGM handle
- numFieldIds
- IN: Number of field IDs that are being provided in fieldIds[]. Must be between 1 and DCGM_MAX_FIELD_IDS_PER_FIELD_GROUP.
- fieldIds
- IN: Field IDs to be added to the newly-created field group
- fieldGroupName
- IN: Unique name for this group of fields. This must not be the same as any existing field groups.
- dcgmFieldGroupId
- OUT: Handle to the newly-created field group
Returns
- DCGM_ST_OK if the field group was successfully created.
- DCGM_ST_BADPARAM if any parameters were bad
- DCGM_ST_INIT_ERROR if the library has not been successfully initialized.
- DCGM_ST_MAX_LIMIT if too many field groups already exist
Description
Used to create a group of fields and return the handle in dcgmFieldGroupId
- dcgmReturn_t dcgmFieldGroupDestroy ( dcgmHandle_t dcgmHandle, dcgmFieldGrp_t dcgmFieldGroupId )
-
Parameters
- dcgmHandle
- IN: DCGM handle
- dcgmFieldGroupId
- IN: Field group to remove
Returns
- DCGM_ST_OK if the field group was successfully removed
- DCGM_ST_BADPARAM if any parameters were bad
- DCGM_ST_INIT_ERROR if the library has not been successfully initialized.
Description
Used to remove a field group that was created with dcgmFieldGroupCreate
- dcgmReturn_t dcgmFieldGroupGetAll ( dcgmHandle_t dcgmHandle, dcgmAllFieldGroup_t* allGroupInfo )
-
Parameters
- dcgmHandle
- IN: DCGM handle
- allGroupInfo
- IN/OUT: Info about all of the field groups that exist. .version should be set to dcgmAllFieldGroup_version before this call.
Returns
- DCGM_ST_OK if the field group info was successfully returned
- DCGM_ST_BADPARAM if any parameters were bad
- DCGM_ST_INIT_ERROR if the library has not been successfully initialized.
- DCGM_ST_VER_MISMATCH if .version is not set or is invalid.
Description
Used to get information about all field groups in the system.
- dcgmReturn_t dcgmFieldGroupGetInfo ( dcgmHandle_t dcgmHandle, dcgmFieldGroupInfo_t* fieldGroupInfo )
-
Parameters
- dcgmHandle
- IN: DCGM handle
- fieldGroupInfo
- IN/OUT: Info about all of the field groups that exist. .version should be set to dcgmFieldGroupInfo_version before this call .fieldGroupId should contain the fieldGroupId you are interested in querying information for.
Returns
- DCGM_ST_OK if the field group info was returned successfully
- DCGM_ST_BADPARAM if any parameters were bad
- DCGM_ST_INIT_ERROR if the library has not been successfully initialized.
- DCGM_ST_VER_MISMATCH if .version is not set or is invalid.
Description
Used to get information about a field group that was created with dcgmFieldGroupCreate.