How to modify training resources

You can modify training resources, such as to alter requirements.

Procedure

  1. Find the custom resource of the algorithm for which you wish to alter the default resource requirements by running the following command:

    oc get algorithms
    
  2. This should return something similar to the following:

    oc get algorithms
    

    Output:

    NAME                AGE
    change-risk         46h
    log-anomaly         46h
    similar-incidents   46h
    
  3. These CRs contain all the algorithm specifications. You can go ahead and edit the specific algorithm by running:

    oc edit algorithm <name>
    
  4. Then you decode the spec.manifestBase64 field. Once decoded you see a resources field defined as follows:

       resources:
          requests:
             cpu: 2
             memory: 4Gi
          limits:
             cpu: 2
             memory: 4Gi
    

    Note: You can edit requests and limits (For training algorithms, make sure that the limits=requests), re-encode to base64, and then replace the manifestBase64 field in the CR with this newly encoded manifest.

  5. Save the changes, and proceed with your training.