35 Commits
Author SHA1 Message Date
Amir IbrahimandGitHub 49f4eaadd2 feat: add Flux integration and e2e tests (#3561)
* test: add Flux framework integration and e2e tests

Signed-off-by: Amir380-A <[email protected]>

* fix: fix integration and e2e

Signed-off-by: Amir380-A <[email protected]>

* fix: EOF linting issue

Signed-off-by: Amir380-A <[email protected]>

* chore: add logs for E2E ClusterTrainingRuntimes in Github Actions

Signed-off-by: Amir380-A <[email protected]>

* feat: add Flux runtime to Helm chart

Signed-off-by: Amir380-A <[email protected]>

* fix: fix EOF linting issue

Signed-off-by: Amir380-A <[email protected]>

* fix: install Flux runtime only for E2E tests

Signed-off-by: Amir380-A <[email protected]>

* chore: regenerate Helm chart docs and generated assets

Signed-off-by: Amir380-A <[email protected]>

* fix: retry failed deepspeed CI dependency

Signed-off-by: Amir380-A <[email protected]>

* revert back to the previous commit

Signed-off-by: Amir380-A <[email protected]>

* fix(e2e): install Flux runtime only during E2E setup

Signed-off-by: Amir380-A <[email protected]>

* fix: fix linting issue

Signed-off-by: Amir380-A <[email protected]>

* fix: fix runtimeRef for CI

Signed-off-by: Amir380-A <[email protected]>

* fix: fix flux examples runtimeref

Signed-off-by: Amir380-A <[email protected]>

---------

Signed-off-by: Amir380-A <[email protected]>
Signed-off-by: Amir Ibrahim <[email protected]>
2026-07-02 15:21:31 +00:00
a6e862ee0c fix(runtimes): set defaultMode on MPI SSH Secret volume (#3649)
* fix(runtimes): set file modes on MPI SSH secret volume

Set per-item file modes on the MPI SSH auth Secret volume to prevent
the private key from being world-readable inside training pods.

Private key uses 0o640 (not 0o600) because the builtin
deepspeed-distributed and mlx-distributed runtimes run as
runAsUser: 1000 while Secret volumes mount as root:root.

A volume-level DefaultMode of 0o400 is added as defense-in-depth
for any future items added without an explicit per-item mode.

Fixes #3262

Signed-off-by: Dmytro Hryshchenko <[email protected]>

* docs: update pkg/constants/constants.go

Co-authored-by: Andrey Velichkevich <[email protected]>
Signed-off-by: Dmytro Hryshchenko <[email protected]>

---------

Signed-off-by: Dmytro Hryshchenko <[email protected]>
Signed-off-by: Dmytro Hryshchenko <[email protected]>
Co-authored-by: Andrey Velichkevich <[email protected]>

Co-authored-by: Hanzo Dev <[email protected]>
2026-06-24 10:40:35 +00:00
Krish GargandGitHub 4f8920c902 feat(api): Add terminationGracePeriodSeconds to PodSpecPatch in TrainJob (#3324)
Adds terminationGracePeriodSeconds field to PodSpecPatch so users can
configure pod termination grace period per TrainJob via RuntimePatches.

This is needed for distributed training with PyTorch Elastic (torchrun)
where large models (70B+ parameters) require more than the default 30s
to complete JIT checkpointing before SIGKILL on node drain or TrainJob
pause.

No changes to merge logic in trainingruntime.go are required since the
existing StrategicMergePatch applied at batchv1.JobTemplateSpec level
already handles this field automatically.

Closes #3285

Signed-off-by: krishdef7 <[email protected]>
2026-05-26 17:36:09 +00:00
Yash AgarwalandGitHub 587010f54d feat: add activeDeadlineSeconds (#3258)
* feat(api): add ActiveDeadlineSeconds and TTLSecondsAfterFinished to Trainer APIs

- Add ActiveDeadlineSeconds *int64 to TrainJobSpec (immutable, min=1)
  with reason constant TrainJobDeadlineExceededReason="DeadlineExceeded"
- Add TTLSecondsAfterFinished *int32 to TrainingRuntimeSpec (min=0)
  with cross-field CEL rules blocking conflicting lifecycle fields
  in the JobSet/Job template
- Add TrainJobDeadlineExceededMessage to constants
- Regenerate zz_generated.deepcopy.go

Part of KEP-2899

Signed-off-by: XploY04 <[email protected]>

* feat(controller): add TTL-based auto-deletion for finished TrainJobs

- Add early-exit guard in Reconcile before prevTrainJob DeepCopy and
  removeFailedCondition, mirroring the Kubernetes Job controller pattern.
  Once a TrainJob is terminal (Complete or Failed), only TTL cleanup runs.
- Add fetchTTLFromRuntime helper to retrieve TTLSecondsAfterFinished from
  the referenced TrainingRuntime or ClusterTrainingRuntime.
- Add reconcileTTL helper to delete finished TrainJobs after their TTL
  expires, or requeue at the exact expiry time.

Part of KEP-2899

Signed-off-by: XploY04 <[email protected]>

* feat(controller): enforce ActiveDeadlineSeconds on TrainJobs

- Add reconcileDeadline helper to terminate running TrainJobs that
  exceed their ActiveDeadlineSeconds.
- Handle job suspension: StartTime is determined by the LastTransitionTime
  of the Suspended=False condition (if it exists) to ensure the deadline
  timer resets correctly upon resume.
- Jobs exceeding the deadline are moved to a Failed state with
  reason DeadlineExceeded.

Part of KEP-2899

Signed-off-by: XploY04 <[email protected]>

* feat(webhooks): warn on short ttlSecondsAfterFinished

- Add an admission warning to both TrainingRuntime and
  ClusterTrainingRuntime webhooks if the TTLSecondsAfterFinished
  is configured to less than 60 seconds, as this may cause
  unexpected data/log loss for data scientists due to overly
  aggressive cleanup.

Part of KEP-2899

Signed-off-by: XploY04 <[email protected]>

* test: add integration tests for TrainJob TTL and deadline lifecycle

- Add integration tests for DeadlineExceeded behavior in TrainJob controller
- Add integration tests for TTL validation and warnings in webhooks

Part of KEP-2899

Signed-off-by: XploY04 <[email protected]>

* cleanup

Signed-off-by: XploY04 <[email protected]>

* fix: ensure JobSet is suspended on expiration and fix webhook test regress

Signed-off-by: XploY04 <[email protected]>

* fix(controller): return errors from fetchTTLFromRuntime for proper requeue

Signed-off-by: XploY04 <[email protected]>

* test: remove unused wantWarning from webhook tests

Signed-off-by: XploY04 <[email protected]>

* fix

Signed-off-by: XploY04 <[email protected]>

* feat: Remove  from TrainingRuntime and ClusterTrainingRuntime specifications and associated validation.

Signed-off-by: XploY04 <[email protected]>

* fix(api): restore `activeDeadlineSeconds` validation rule on TrainingRuntime

Signed-off-by: XploY04 <[email protected]>

* refactor: remove unnecessary blank lines and improve logging in ClusterTrainingRuntime validation

Signed-off-by: XploY04 <[email protected]>

* feat: add activeDeadlineSeconds field to TrainJobSpec and update related tests

Signed-off-by: XploY04 <[email protected]>

* Remove unnecessary newline in test file

Signed-off-by: Yash Agarwal <[email protected]>

* Remove unnecessary newline in trainingruntime_webhook_test.go

Signed-off-by: Yash Agarwal <[email protected]>

* refactor: remove unnecessary blank lines in TrainJob reconciliation and deadline tests

Signed-off-by: XploY04 <[email protected]>

* feat: change ActiveDeadlineSeconds from pointer to value type and update related code

Signed-off-by: XploY04 <[email protected]>

* feat: add condition check for TrainJob deadline exceeded before suspending

Signed-off-by: XploY04 <[email protected]>

* feat: enhance TrainJob deadline handling and suspend logic

Signed-off-by: XploY04 <[email protected]>

* feat: enhance TrainJob deadline handling and suspend logic

Signed-off-by: XploY04 <[email protected]>

* fix

Signed-off-by: XploY04 <[email protected]>

* feat: change ActiveDeadlineSeconds to pointer type and update related logic

Signed-off-by: XploY04 <[email protected]>

* feat: ensure requeueAfter is at least 1 second when deadline is exceeded

Signed-off-by: XploY04 <[email protected]>

* feat: change ActiveDeadlineSeconds from pointer to value type and update related logic

Signed-off-by: XploY04 <[email protected]>

* fix: remove early return for finished TrainJobs to prevent status sync issues

The early return was preventing the controller from syncing JobSet
status updates for finished TrainJobs, causing e2e tests to timeout
waiting for conditions that never got updated.

This fix restores the upstream behavior where finished TrainJobs still
go through status reconciliation (though reconcileObjects is skipped).

Signed-off-by: XploY04 <[email protected]>

* fix

Signed-off-by: XploY04 <[email protected]>

* fix: remove x-kubernetes-validations for activeDeadlineSeconds in TrainingRuntime CRDs

Signed-off-by: XploY04 <[email protected]>

* fix: update validation message for ActiveDeadlineSeconds to be more generic

Signed-off-by: XploY04 <[email protected]>

* replacing suspend with delete

Signed-off-by: XploY04 <[email protected]>

* fix: remove SpecLabel and SpecAnnotation methods from TrainJobWrapper

Signed-off-by: XploY04 <[email protected]>

* fix: remove annotations field from TrainJobSpec and CRD definitions

Signed-off-by: XploY04 <[email protected]>

* ensure JobSet deletion in e2e tests

Signed-off-by: XploY04 <[email protected]>

* fix: add JobSet APIs to the scheme in e2e tests

Signed-off-by: XploY04 <[email protected]>

* fix: simplify error handling in Reconcile method of TrainJobReconciler

Signed-off-by: XploY04 <[email protected]>

---------

Signed-off-by: XploY04 <[email protected]>
Signed-off-by: Yash Agarwal <[email protected]>
2026-03-13 18:37:31 +00:00
37c8a07a8a feat(api): Replace PodTemplateOverrides with RuntimePatches API (#3309)
* feat(api): Replace PodTemplateOverrides with RuntimePatches API

Signed-off-by: Andrey Velichkevich <[email protected]>

* Update goal with RuntimePatches API

Signed-off-by: Andrey Velichkevich <[email protected]>

* Add diagram for RuntimePatches

Signed-off-by: Andrey Velichkevich <[email protected]>

* feat(api): Replace PodTemplateOverrides with RuntimePatches API

Signed-off-by: Antonin Stefanutti <[email protected]>

* Fix kube lint errors

Signed-off-by: Antonin Stefanutti <[email protected]>

* Update Python models

Signed-off-by: Antonin Stefanutti <[email protected]>

* Enable maxlength Kube-API-Linter rule

Signed-off-by: Antonin Stefanutti <[email protected]>

* Restore manger field IsDomainPrefixedPath validation

Signed-off-by: Antonin Stefanutti <[email protected]>

* Fix integration tests

Signed-off-by: Antonin Stefanutti <[email protected]>

* Apply StrategicMergePatch to batchv1.JobTemplateSpec

Signed-off-by: Antonin Stefanutti <[email protected]>

---------

Signed-off-by: Andrey Velichkevich <[email protected]>
Signed-off-by: Antonin Stefanutti <[email protected]>
Co-authored-by: Andrey Velichkevich <[email protected]>
2026-03-12 16:29:44 +00:00
Krishna GuptaandGitHub ccaf20bc20 feat(runtimes): Add XGBoost runtime(KEP-2598) (#3200)
* Add XGBoost runtime plugin scaffold and register in framework

Signed-off-by: Krishna-kg732 <[email protected]>
Signed-off-by: krishna-kg732 <[email protected]>

* regenerated assets

Signed-off-by: Krishna-kg732 <[email protected]>
Signed-off-by: krishna-kg732 <[email protected]>

* Add XGBoost plugin unit tests and update framework test registry

Signed-off-by: Krishna-kg732 <[email protected]>
Signed-off-by: krishna-kg732 <[email protected]>

* added :Runtime image , unit tests for :(Resources are not set, Resources are set in TrainJob) ,using the ContainerTrainerPort instead of default port

Signed-off-by: krishna-kg732 <[email protected]>

* minor changes

Signed-off-by: krishna-kg732 <[email protected]>

* added plainML fallback(JAX+XGBOOST)

Signed-off-by: krishna-kg732 <[email protected]>

* test: add XGBoost runtime resource resolution unit tests

- Add test case for resources set in Runtime only
- Add test case for resources set in both Runtime and TrainJob
- Add xgboost_distributed.yaml ClusterTrainingRuntime manifest
- Update kustomization.yaml with xgboost-runtime image

Addresses feedback from PR #3200 for complete resource resolution test coverage.

Signed-off-by: krishna-kg732 <[email protected]>

* added autogenerat3ed files

Signed-off-by: krishna-kg732 <[email protected]>

* CI fixes

Signed-off-by: krishna-kg732 <[email protected]>

* chore: fix ci lint errors

Signed-off-by: krishna-kg732 <[email protected]>

* Add XGBoost integration and E2E tests, fix Validate guard clause and nil safety

Signed-off-by: krishna-kg732 <[email protected]>

* trigger ci

Signed-off-by: krishna-kg732 <[email protected]>

* fix: Add XGBoost support to test wrapper, CEL validation, and CI publish workflow

- Add XGBoostPolicy() method to MLPolicySourceWrapper for integration tests
- Add has(self.xgboost) to MLPolicy CEL mutual-exclusivity validation rule
- Regenerate CRD manifests with updated CEL rule
- Add xgboost-runtime to build-and-push-images CI workflow
- Add XGBoost image build step to E2E setup script (commented out due to Kind bug)

Signed-off-by: krishna-kg732 <[email protected]>

* docs: Add XGBoost distributed training example notebook

Add example notebook demonstrating distributed XGBoost training using
the Kubeflow Trainer SDK and the xgboost-distributed ClusterTrainingRuntime.

The notebook uses the modern XGBoost Collective API with RabitTracker
for distributed coordination and synthetic classification data.

Signed-off-by: krishna-kg732 <[email protected]>

* test: Skip XGBoost E2E test until runtime image is published

Signed-off-by: krishna-kg732 <[email protected]>

* chore : address review comments

Signed-off-by: krishna-kg732 <[email protected]>

* chore:resolve merge conflicts

Signed-off-by: krishna-kg732 <[email protected]>

---------

Signed-off-by: Krishna-kg732 <[email protected]>
Signed-off-by: krishna-kg732 <[email protected]>
2026-03-10 10:04:42 +00:00
Andrey VelichkevichandGitHub 63d928468c feat(api): BREAKING CHANGE: Remove numProcPerNode from Torch API (#3239)
* feat(api): BREAKING CHANGE: Remove numProcPerNode from Torch API

Signed-off-by: Andrey Velichkevich <[email protected]>

* Remove trainer_v1alpha1_torch_elastic_policy.py from Py models

Signed-off-by: Andrey Velichkevich <[email protected]>

* Fix numNodes validation in torchtune

Signed-off-by: Andrey Velichkevich <[email protected]>

---------

Signed-off-by: Andrey Velichkevich <[email protected]>
2026-03-01 06:53:03 +00:00
Andrey VelichkevichandGitHub 60004df3d3 feat(api): BREAKING CHANGE – Remove ElasticPolicy API (#3235)
Signed-off-by: Andrey Velichkevich <[email protected]>
2026-02-24 20:58:47 +00:00
Andrey VelichkevichandGitHub ea044c39c4 feat(api): Fix immutability of the TrainJob APIs (#3157)
* feat(api): Fix immutability for TrainJob APIs

Signed-off-by: Andrey Velichkevich <[email protected]>

* Only validate immutability of podTemplateOverride API

Signed-off-by: Andrey Velichkevich <[email protected]>

* Fix CEL rule

Signed-off-by: Andrey Velichkevich <[email protected]>

* Use listType atomic for PodTemplateOverrideTargetJob

Signed-off-by: Andrey Velichkevich <[email protected]>

* Remove PodTemplateOverrides CEL validation

Signed-off-by: Andrey Velichkevich <[email protected]>

* Test image immutability

Signed-off-by: Andrey Velichkevich <[email protected]>

---------

Signed-off-by: Andrey Velichkevich <[email protected]>
2026-02-09 19:23:13 +00:00
Tomas TormoandGitHub 62812f9ce3 feat(runtimes): Add JAX training runtime (#3151)
Signed-off-by: mahdikhashan <[email protected]>
Signed-off-by: Tomas Tormo <[email protected]>
2026-02-06 18:15:22 +00:00
Antonin StefanuttiandGitHub 7755220575 chore(ci): Enable Kubernetes API Linter (#2858)
* chore(ci): Enable Kubernetes API Linter

Signed-off-by: Antonin Stefanutti <[email protected]>

* lint files

Signed-off-by: Antonin Stefanutti <[email protected]>

* Generate

Signed-off-by: Antonin Stefanutti <[email protected]>

* Review

Signed-off-by: Antonin Stefanutti <[email protected]>

* Fix golangci-lint target

Signed-off-by: Antonin Stefanutti <[email protected]>

* Fix commands max length

Signed-off-by: Antonin Stefanutti <[email protected]>

* Re: Fix golangci-lint target

Signed-off-by: Antonin Stefanutti <[email protected]>

* Enable the integers linter

Signed-off-by: Antonin Stefanutti <[email protected]>

* Disable maxlength linter

Signed-off-by: Antonin Stefanutti <[email protected]>

* make generate

Signed-off-by: Antonin Stefanutti <[email protected]>

* Make fields optional

Signed-off-by: Antonin Stefanutti <[email protected]>

* Fix Suspended field in JobStatus

Signed-off-by: Antonin Stefanutti <[email protected]>

---------

Signed-off-by: Antonin Stefanutti <[email protected]>
2025-10-17 14:40:59 +00:00
Xigang WangandGitHub 1d01c440b7 feat(api): Add PodTemplateOverrides API into TrainJob (#2785)
Signed-off-by: xigang <[email protected]>
2025-10-09 10:08:14 +00:00
Antonin StefanuttiandGitHub e9586f9c78 feat(api): Sync TrainJob JobsStatus from JobSet ReplicatedJobsStatus (#2802)
* feat(api): Sync TrainJob JobsStatus from JobSet ReplicatedJobsStatus

Signed-off-by: Antonin Stefanutti <[email protected]>

* Add integration tests

Signed-off-by: Antonin Stefanutti <[email protected]>

* Update e2e tests

Signed-off-by: Antonin Stefanutti <[email protected]>

* Remove extra check

Signed-off-by: Antonin Stefanutti <[email protected]>

* Sort JobsStatus in e2e tests

Signed-off-by: Antonin Stefanutti <[email protected]>

* Fix e2e test for MPI job

Signed-off-by: Antonin Stefanutti <[email protected]>

* Fail-fast when multiple terminal condition and JobsStatus plugins exist

Signed-off-by: Antonin Stefanutti <[email protected]>

* Fold TerminalCondition and JobsStatus plugins

Signed-off-by: Antonin Stefanutti <[email protected]>

---------

Signed-off-by: Antonin Stefanutti <[email protected]>
2025-10-07 13:19:12 +00:00
Tsubasa NagasawaandGitHub d05f5d797d chore: deflake test to ensure runtime is created before creating trainjob (#2807)
Signed-off-by: Tsubasa Nagasawa <[email protected]>
2025-08-29 06:12:22 +00:00
Andrey VelichkevichandGitHub 8655798f02 fix(module): Change Go module name to v2 (#2707)
* fix(module): Change Go module name to v2

Signed-off-by: Andrey Velichkevich <[email protected]>

* Bump x/net to v0.38.0

Signed-off-by: Andrey Velichkevich <[email protected]>

---------

Signed-off-by: Andrey Velichkevich <[email protected]>
2025-07-03 17:46:20 +00:00
434d953004 feat(controller): Implement PodSpecOverride API (#2614)
* feat(controller): Implement PodSpecOverride API

Signed-off-by: Andrey Velichkevich <[email protected]>

* Update API comments

Signed-off-by: Andrey Velichkevich <[email protected]>

* Fix InitContainers override

Signed-off-by: Andrey Velichkevich <[email protected]>

* Fix generate

Signed-off-by: Andrey Velichkevich <[email protected]>

* Update pkg/apis/trainer/v1alpha1/trainjob_types.go

Co-authored-by: Shao Wang <[email protected]>
Signed-off-by: Andrey Velichkevich <[email protected]>

* Change API to targetJob and add validation

Signed-off-by: Andrey Velichkevich <[email protected]>

* Add unit test for the JobSet builder

Signed-off-by: Andrey Velichkevich <[email protected]>

* Add integration tests

Signed-off-by: Andrey Velichkevich <[email protected]>

* Update pkg/apis/trainer/v1alpha1/trainjob_types.go

Co-authored-by: Shao Wang <[email protected]>
Signed-off-by: Andrey Velichkevich <[email protected]>

* Update pkg/apis/trainer/v1alpha1/trainjob_types.go

Co-authored-by: Shao Wang <[email protected]>
Signed-off-by: Andrey Velichkevich <[email protected]>

* Update pkg/apis/trainer/v1alpha1/trainjob_types.go

Co-authored-by: Antonin Stefanutti <[email protected]>
Signed-off-by: Andrey Velichkevich <[email protected]>

* Merge PodSpecOverrides before the build phase

Signed-off-by: Antonin Stefanutti <[email protected]>

* Fix make generate

Signed-off-by: Antonin Stefanutti <[email protected]>

* Fix PodSpec SMT patch unmarshalling into JobSet template

Signed-off-by: Antonin Stefanutti <[email protected]>

* Add UT for volumes PodSpecOverrides

Signed-off-by: Antonin Stefanutti <[email protected]>

* Add UT for tolerations PodSpecOverrides

Signed-off-by: Antonin Stefanutti <[email protected]>

* Add UT for node selector PodSpecOverrides

Signed-off-by: Antonin Stefanutti <[email protected]>

* Revert back to using TargetJobs []PodSpecOverrideTargetJob

Signed-off-by: Antonin Stefanutti <[email protected]>

* Run make fmt

Signed-off-by: Antonin Stefanutti <[email protected]>

* Add target jobs unicity validation for PodSpecOverrides

Signed-off-by: Antonin Stefanutti <[email protected]>

* Update with code review from @tenzen-y

Signed-off-by: Antonin Stefanutti <[email protected]>

---------

Signed-off-by: Andrey Velichkevich <[email protected]>
Signed-off-by: Antonin Stefanutti <[email protected]>
Co-authored-by: Shao Wang <[email protected]>
Co-authored-by: Antonin Stefanutti <[email protected]>
Co-authored-by: Antonin Stefanutti <[email protected]>
2025-06-06 17:04:18 +00:00
Antonin StefanuttiandGitHub 2af1136113 Remove TrainJobCreated condition (#2621)
* Remove TrainJobCreated condition

Signed-off-by: Antonin Stefanutti <[email protected]>

* Update KEP-2170 proposal

Signed-off-by: Antonin Stefanutti <[email protected]>

* Remove Created condition from SDK

Signed-off-by: Antonin Stefanutti <[email protected]>

* Default TrainJob status to Created unconditionally

Signed-off-by: Antonin Stefanutti <[email protected]>

* Set Failed condition on TrainJob runtime creation errors

Signed-off-by: Antonin Stefanutti <[email protected]>

* Emit a warning event upon TrainJob resources reconcile error

Signed-off-by: Antonin Stefanutti <[email protected]>

* Update TrainJob resources creation failed event

Signed-off-by: Antonin Stefanutti <[email protected]>

* Truncate event message to the maximum length limit

Signed-off-by: Antonin Stefanutti <[email protected]>

* Update state diagram in KEP-2170

Signed-off-by: Antonin Stefanutti <[email protected]>

* Append ellipsis to event message if it's truncated

Signed-off-by: Antonin Stefanutti <[email protected]>

---------

Signed-off-by: Antonin Stefanutti <[email protected]>
2025-05-02 17:59:05 +00:00
Yuki IwaiandGitHub cfc44b807b Implement trainer.kubeflow.org/resource-in-use finalizer mechanism to ClusterTrainingRuntime (#2625)
Implement trainer.kubeflow.org/resource-in-use finalizer mechanism to ClusterTrainingRuntime

Signed-off-by: Yuki Iwai <[email protected]>
2025-05-02 01:27:04 +00:00
Yuki IwaiandGitHub f5a2d0f250 Implement trainer.kubeflow.org/resource-in-use finalizer mechanism to TrainingRuntime (#2608)
* Implement trainer.kubeflow.org/resource-in-use finalizer mechanism to TrainingRuntime

Signed-off-by: Yuki Iwai <[email protected]>

# Conflicts:
#	pkg/constants/constants.go

* Reduce permissions

Signed-off-by: Yuki Iwai <[email protected]>

* Dispatch reconciliations even when TrainJob is updated

Signed-off-by: Yuki Iwai <[email protected]>

---------

Signed-off-by: Yuki Iwai <[email protected]>
2025-05-01 20:17:04 +00:00
AsklvandGitHub ccbd58e4ee test(runtime): add UT for torch runtime valid function. (#2560)
Signed-off-by: Asklv <[email protected]>
2025-03-26 07:47:04 +00:00
AsklvandGitHub 07ce28219c feat(runtime): remove needless Launcher chainer. (#2558)
Signed-off-by: Asklv <[email protected]>
2025-03-24 11:14:05 +00:00
Andrey VelichkevichandGitHub eb1ee9d0f4 feat(sdk): Support MPI-based TrainJobs (#2545)
* feat(sdk): Support MPI-based TrainJobs

Signed-off-by: Andrey Velichkevich <[email protected]>

* Refactor list_runtimes

Signed-off-by: Andrey Velichkevich <[email protected]>

* Fix example

Signed-off-by: Andrey Velichkevich <[email protected]>

* Add Runtime Trainer object

Signed-off-by: Andrey Velichkevich <[email protected]>

* Update for new Runtime object

Signed-off-by: Andrey Velichkevich <[email protected]>

* Implement get_runtime API

Signed-off-by: Andrey Velichkevich <[email protected]>

* Fix Torch example

Signed-off-by: Andrey Velichkevich <[email protected]>

* Remove un-unsed consts

Signed-off-by: Andrey Velichkevich <[email protected]>

* Update func args

Signed-off-by: Andrey Velichkevich <[email protected]>

* Update SDK constants

Signed-off-by: Andrey Velichkevich <[email protected]>

* Change to 16Gi

Signed-off-by: Andrey Velichkevich <[email protected]>

* Fix container name for MPI

Signed-off-by: Andrey Velichkevich <[email protected]>

* Keep launcher container for MPI

Signed-off-by: Andrey Velichkevich <[email protected]>

---------

Signed-off-by: Andrey Velichkevich <[email protected]>
2025-03-20 18:08:02 +00:00
Yuki IwaiandGitHub 50d6be8324 Construct Trainer based on trainer.kubeflow.org/trainjob-ancestor-step label (#2548)
Signed-off-by: Yuki Iwai <[email protected]>
2025-03-20 14:01:57 +00:00
Yuki IwaiandGitHub 64404f6565 Store the TrainingRuntime numNodes as runtime.Info.PodSet.Count (#2539)
Signed-off-by: Yuki Iwai <[email protected]>
2025-03-18 15:55:44 +00:00
Andrey VelichkevichandGitHub 239b27d311 feat(controller): Refactor the Initializer APIs of TrainJob (#2523)
* feat(controller): Refactor the Initializer APIs of TrainJob

Signed-off-by: Andrey Velichkevich <[email protected]>

* Fix go unit test

Signed-off-by: Andrey Velichkevich <[email protected]>

* Fix integration test

Signed-off-by: Andrey Velichkevich <[email protected]>

---------

Signed-off-by: Andrey Velichkevich <[email protected]>
2025-03-17 07:15:51 +00:00
a589903c24 KEP-2170: Adding validation webhook for v2 trainjob (#2307)
Signed-off-by: Akshay Chitneni <[email protected]>
Co-authored-by: Akshay Chitneni <[email protected]>
2025-03-16 03:41:51 +00:00
f98108aa6b Fix #2407: Cap nproc_per_node based on CPU resources for PyTorch TrainJob (#2492)
* Fix #2407: Cap nproc_per_node based on CPU resources for PyTorch TrainJob

Signed-off-by: Diasker <[email protected]>

* Refactor the fix using resource.MustParse and RoundUp

Signed-off-by: Diasker <[email protected]>

* remove unecessary log message

Signed-off-by: Diasker <[email protected]>

* update test case to expect nproc_per_node=1 without GPU

Signed-off-by: Diasker <[email protected]>

* Implement numProcPerNode=cpu option and refactor tests.

Signed-off-by: Diasker <[email protected]>

* refactor: improve torch test cases

Signed-off-by: Diasker <[email protected]>

* remove the redundant logic

Signed-off-by: Diasker <[email protected]>

* Update pkg/runtime/framework/plugins/torch/torch.go

Co-authored-by: Yuki Iwai <[email protected]>
Signed-off-by: Diasker <[email protected]>

* Update pkg/runtime/framework/plugins/torch/torch_test.go

Co-authored-by: Yuki Iwai <[email protected]>
Signed-off-by: Diasker <[email protected]>

* simply code and remove redundant comments

Signed-off-by: Diasker <[email protected]>

* Update pkg/runtime/framework/plugins/torch/torch.go

Co-authored-by: Yuki Iwai <[email protected]>
Signed-off-by: Diasker <[email protected]>

* Update pkg/runtime/framework/plugins/torch/torch_test.go

Co-authored-by: Yuki Iwai <[email protected]>
Signed-off-by: Diasker <[email protected]>

* Update pkg/runtime/framework/plugins/torch/torch.go

Co-authored-by: Yuki Iwai <[email protected]>
Signed-off-by: Diasker <[email protected]>

* remove get_num_proc_per_node for sdk and simply torch.go

Signed-off-by: Diasker <[email protected]>

* Update expected nproc_per_node value in trainjob_controller_test.go

Signed-off-by: Diasker <[email protected]>

* Update expected nproc_per_node value in trainjob_controller_test.go and remove redundant code of sdk

Signed-off-by: Diasker <[email protected]>

* update trainjob_controller_test.go

Signed-off-by: Diasker <[email protected]>

* update torch.go

Signed-off-by: Diasker <[email protected]>

---------

Signed-off-by: Diasker <[email protected]>
Signed-off-by: Diasker <[email protected]>
Co-authored-by: Yuki Iwai <[email protected]>
2025-03-13 19:29:37 +00:00
Yuki IwaiandGitHub e8d6727da6 Implemenet MPI Plugin for OpenMPI (#2493)
* Implemenet MPI Plugin for OpenMPI

Signed-off-by: Yuki Iwai <[email protected]>

* Directory pass the JobSetApplyconfiguration to RuntimeInfo

Signed-off-by: Yuki Iwai <[email protected]>

* Make repeated string as constants

Signed-off-by: Yuki Iwai <[email protected]>

* Use numNodes=1 as default mpi_distributed ClusterTrainingRuntime

Signed-off-by: Yuki Iwai <[email protected]>

* Remove unused errors

Signed-off-by: Yuki Iwai <[email protected]>

* Rename runLauncherAsWorker with runLauncherAsNode

Signed-off-by: Yuki Iwai <[email protected]>

* Fix unintended constants usage for ModelMountPath

Signed-off-by: Yuki Iwai <[email protected]>

* Rename SecretDataComparer with MPISecretDataComparer

Signed-off-by: Yuki Iwai <[email protected]>

* Add TODO STAEEMENT to deprecated env wrappers.

Signed-off-by: Yuki Iwai <[email protected]>

---------

Signed-off-by: Yuki Iwai <[email protected]>
2025-03-13 05:00:56 +00:00
Yuki IwaiandGitHub 1ed7b69d8c Move TrainJob marker defaulting and validation integration tests to test/integration/webhooks pkg (#2486)
Signed-off-by: Yuki Iwai <[email protected]>
2025-03-07 02:46:31 +00:00
0cae7e1b0b feat(controller): Integrate DependsOn API (#2484)
* feat(controller): Integrate DependsOn API

Signed-off-by: Andrey Velichkevich <[email protected]>

* Use go for unit test

Signed-off-by: Andrey Velichkevich <[email protected]>

* Update Makefile

Co-authored-by: Yuki Iwai <[email protected]>
Signed-off-by: Andrey Velichkevich <[email protected]>

* Update Makefile

Co-authored-by: Yuki Iwai <[email protected]>
Signed-off-by: Andrey Velichkevich <[email protected]>

* Fix integration test

Signed-off-by: Andrey Velichkevich <[email protected]>

* Fix e2e

Signed-off-by: Andrey Velichkevich <[email protected]>

* Exit 1 if e2e fails

Signed-off-by: Andrey Velichkevich <[email protected]>

---------

Signed-off-by: Andrey Velichkevich <[email protected]>
Co-authored-by: Yuki Iwai <[email protected]>
2025-03-07 01:11:34 +00:00
Yuki IwaiandGitHub a3a1324f41 Implement UTs for PlainML plugin (#2469)
Signed-off-by: Yuki Iwai <[email protected]>
2025-03-05 04:40:06 +00:00
Antonin StefanuttiandGitHub d954ed3272 KEP-2170: Add validation to Torch numProcPerNode field (#2409)
Signed-off-by: Antonin Stefanutti <[email protected]>
2025-02-14 20:57:37 +00:00
a41677611e KEP: 2170: Adding cel validations on TrainingRuntime/ClusterTrainingRuntime CRDs (#2313)
Signed-off-by: Akshay Chitneni <[email protected]>
Co-authored-by: Akshay Chitneni <[email protected]>
2025-02-14 19:40:37 +00:00
Yuki IwaiandGitHub 3dafb823ae IntegraionTests: Waiting for expected conditions before emulate JobSet controller manager (#2425)
Signed-off-by: Yuki Iwai <[email protected]>
2025-02-10 21:03:13 +00:00
Andrey VelichkevichandGitHub 1ff1d8ad28 Update the naming conventions for Kubeflow Trainer (#2415)
* Update the naming conventions for Kubeflow Trainer

Signed-off-by: Andrey Velichkevich <[email protected]>

* Fix webhooks

Signed-off-by: Andrey Velichkevich <[email protected]>

* Fix paths for webhooks

Signed-off-by: Andrey Velichkevich <[email protected]>

* Update go test cmd

Signed-off-by: Andrey Velichkevich <[email protected]>

* Rename kubeflowv1 to trainer pkg

Signed-off-by: Andrey Velichkevich <[email protected]>

---------

Signed-off-by: Andrey Velichkevich <[email protected]>
2025-02-06 13:48:30 +00:00