Skip to main content
After you create a training task, the platform schedules resources based on the selected Region, Cluster, resource pool, and instance specification, and runs the training command in a container. This document uses console-based form creation as an example to describe the complete configuration process. Before formally submitting a long-running training job, we recommend first using a small-scale task to validate the image, mount path, startup command, and checkpoint writing logic.

Create Training

1. Go to the creation page

  1. Go to Training > Workloads.
  2. On the Personal Tasks tab, click Create.

2. Configure General Settings

First, complete the shared basic settings for PyTorchJob and RayJob. The task type determines the specific settings that must be added later.

Basic information

Environment Information

The runtime environment determines which image the training container uses, which inputs it reads, where it writes outputs, and which cmd it executes after startup. Before creating it, ensure that the image, code path, data path, and output path are ready.
Use separate directories starting with /volume or /mnt as mount paths for storage, datasets, and models to avoid overwriting default image directories such as /opt, /workspace, and /usr. Path conflicts may render dependencies, code, or startup commands unavailable. Container local disks have limited capacity; writing large amounts of data may slow down the system, and local disk data may also be cleared after a restart or migration. Important files, such as training code, datasets, models, checkpoints, and output results, should be written to mounted volumes.

COMPUTE Resources

Compute resources determine the type of resources used by a task, the number of replicas to launch, and the CPU/GPU resources requested by each replica. We recommend completing the configuration in the following order: Resource Type -> Replicas -> Instance Spec -> Quota and Scheduling. 1. Select Resource Type Different resource types affect the available instances, quota validation, resource guarantees, and interruption risks. Select a resource type as needed. 2. Configure Replicas
  • PyTorchJob PyTorchJob has a fixed master node count of 1, while the number of worker nodes can be set to 0. The master node and worker nodes use the same specifications. For distributed training, the number of worker nodes affects the number of replicas that must be scheduled simultaneously. For the total number of task replicas, PyTorchJob typically calculates the number of replicas that must be scheduled simultaneously as 1 + number of worker nodes.
  • RayJob RayJob configures the Head and Worker separately. The number of Heads and their resources are specified in the Ray form, while the number of Workers determines the scale of worker nodes. For the total number of task replicas, RayJob resources are calculated separately for the Head and Worker.
3. Select Instance Spec Resource quantities are calculated based on the role configuration. The specification values on the page are for displaying the resources of a single selected instance specification only. Actual resource quantities depend on the selected specification and number of replicas. 4. Confirm Quota and Scheduling Before submitting, do not consider only whether an individual instance specification is available; also confirm that the entire task can be scheduled simultaneously.
Distributed training uses gang scheduling. The replicas required by a job cannot be assessed solely by summing total resources; it is also necessary to ensure that each replica can be placed on an available node and that all replicas can start simultaneously. If resources are insufficient, the entire job enters the queue and is automatically scheduled once the resource requirements are met, without manual retries.
Priority affects task queuing and scheduling order and may also affect outcomes in resource contention. For more details about low-cost resources, Guarantee, node scheduling policies, and preemption, see Training Advanced Config.

Advanced Options

3. Complete the configuration based on the Task Type

PyTorchJob

PyTorchJob is suitable for running single-node or distributed training jobs based on PyTorch. After completing the general configuration, check carefully whether cmd can correctly start the training script. For PyTorchJob multi-node multi-GPU training, you can use the platform-injected distributed training environment variables in the startup command: The platform also injects task context-related TaskEnv, such as X_USER_NAME, X_ORG_NAME, X_TENANT_ID, X_REGION, X_CLUSTER, and TASK_UUID. If the training script needs to record the task source, region, cluster, or unique task identifier, it can read these variables. Example:
Adjust --nproc_per_node based on the actual number of GPUs per node, and replace train.py with the actual training script.

RayJob

RayJob is suitable for running Ray-based distributed training, scheduling, or parallel computing tasks. After completing the general configuration, pay particular attention to the Head / Worker, Runtime Env, shared storage, and autoscaling settings. After selecting RayJob, pay attention to how Ray is run and its resource usage:
  • A RayJob consists of one Head Pod and multiple Worker Pods.
  • The number of Worker Pods is determined by the number of Workers specified in the creation form. The total number of resource-consuming Pods is typically number of Workers + 1.
  • User code logs for a RayJob are typically viewed through the Submitter Pod.
  • For Ray cluster logs, view the Head Pod or Worker Pods.
  • The startup command for a RayJob is typically a Ray entrypoint, such as python main.py.
For more configuration recommendations on shared storage, auto scaling, Runtime Env, or Debug mode, see Advanced Training Configuration.

4. Submit Creation

Click Create to submit a task. After submission, the task enters the queue and waits to be scheduled. You can view its status in the task list or go to the training task details page to view events, logs, and monitoring. After submitting, return to the task list and search or refresh to verify that the task has been created, then record the task ID. If the creation request has succeeded but the list has not been refreshed in time, search or refresh first to avoid submitting the same task repeatedly. After opening the training task details page, first verify the actual resources, the status of each replica, and the Event. Then review the logs to confirm that training initialization is complete and that training steps are continuing to progress, and check whether outputs and checkpoints are being written to the expected paths. If the task remains queued for an extended period, scheduling fails, or startup fails, first review Event on the training task details page, then check the resource quota, image, mount path, and startup command based on the event information.

Next steps