Skip to content

Commit

Permalink
Put KatibConfig on every install
Browse files Browse the repository at this point in the history
Signed-off-by: Yuki Iwai <[email protected]>
  • Loading branch information
tenzen-y committed Jul 31, 2023
1 parent 202a7bb commit 38de902
Show file tree
Hide file tree
Showing 22 changed files with 424 additions and 121 deletions.
2 changes: 1 addition & 1 deletion docs/developer-guide.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ make build REGISTRY=<image-registry> TAG=<image-tag>

To use your custom images for the Katib components, modify
[Kustomization file](https://github.com/kubeflow/katib/blob/master/manifests/v1beta1/installs/katib-standalone/kustomization.yaml)
and [Katib Config](https://github.com/kubeflow/katib/blob/master/manifests/v1beta1/components/katib-config/katib-config.yaml)
and [Katib Config](https://github.com/kubeflow/katib/blob/master/manifests/v1beta1/installs/katib-standalone/katib-config.yaml)

You can deploy Katib v1beta1 manifests into a Kubernetes cluster as follows:

Expand Down
2 changes: 1 addition & 1 deletion docs/new-algorithm-service.md
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ Then build the Docker image.

### Use the algorithm in Katib.

Update the [Katib config](../manifests/v1beta1/components/katib-config/katib-config.yaml) with the new algorithm entity:
Update the [Katib config](../manifests/v1beta1/installs/katib-standalone/katib-config.yaml) with the new algorithm entity:

```diff
runtime:
Expand Down
59 changes: 0 additions & 59 deletions manifests/v1beta1/components/katib-config/katib-config.yaml

This file was deleted.

21 changes: 0 additions & 21 deletions manifests/v1beta1/components/katib-config/kustomization.yaml

This file was deleted.

This file was deleted.

59 changes: 59 additions & 0 deletions manifests/v1beta1/installs/katib-cert-manager/katib-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
---
apiVersion: config.kubeflow.org/v1beta1
kind: KatibConfig
init:
controller:
webhookPort: 8443
trialResources:
- Job.v1.batch
- TFJob.v1.kubeflow.org
- PyTorchJob.v1.kubeflow.org
- MPIJob.v1.kubeflow.org
- XGBoostJob.v1.kubeflow.org
- MXJob.v1.kubeflow.org
runtime:
metricsCollectors:
- kind: StdOut
image: docker.io/kubeflowkatib/file-metrics-collector:latest
- kind: File
image: docker.io/kubeflowkatib/file-metrics-collector:latest
- kind: TensorFlowEvent
image: docker.io/kubeflowkatib/tfevent-metrics-collector:latest
resources:
limits:
memory: 1Gi
suggestions:
- algorithmName: random
image: docker.io/kubeflowkatib/suggestion-hyperopt:latest
- algorithmName: tpe
image: docker.io/kubeflowkatib/suggestion-hyperopt:latest
- algorithmName: grid
image: docker.io/kubeflowkatib/suggestion-optuna:latest
- algorithmName: hyperband
image: docker.io/kubeflowkatib/suggestion-hyperband:latest
- algorithmName: bayesianoptimization
image: docker.io/kubeflowkatib/suggestion-skopt:latest
- algorithmName: cmaes
image: docker.io/kubeflowkatib/suggestion-goptuna:latest
- algorithmName: sobol
image: docker.io/kubeflowkatib/suggestion-goptuna:latest
- algorithmName: multivariate-tpe
image: docker.io/kubeflowkatib/suggestion-optuna:latest
- algorithmName: enas
image: docker.io/kubeflowkatib/suggestion-enas:latest
resources:
limits:
memory: 200Mi
- algorithmName: darts
image: docker.io/kubeflowkatib/suggestion-darts:latest
- algorithmName: pbt
image: docker.io/kubeflowkatib/suggestion-pbt:latest
persistentVolumeClaimSpec:
accessModes:
- ReadWriteMany
resources:
requests:
storage: 5Gi
earlyStoppings:
- algorithmName: medianstop
image: docker.io/kubeflowkatib/earlystopping-medianstop:latest
10 changes: 8 additions & 2 deletions manifests/v1beta1/installs/katib-cert-manager/kustomization.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,6 @@ resources:
- ../../components/webhook/
# Cert-manager certificate for webhooks
- certificate.yaml
# Katib Config.
- ../../components/katib-config/
images:
- name: docker.io/kubeflowkatib/katib-controller
newName: docker.io/kubeflowkatib/katib-controller
Expand Down Expand Up @@ -61,3 +59,11 @@ vars:

configurations:
- params.yaml

configMapGenerator:
- name: katib-config
behavior: create
files:
- katib-config.yaml
options:
disableNameSuffixHash: true
59 changes: 59 additions & 0 deletions manifests/v1beta1/installs/katib-external-db/katib-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
---
apiVersion: config.kubeflow.org/v1beta1
kind: KatibConfig
init:
controller:
webhookPort: 8443
trialResources:
- Job.v1.batch
- TFJob.v1.kubeflow.org
- PyTorchJob.v1.kubeflow.org
- MPIJob.v1.kubeflow.org
- XGBoostJob.v1.kubeflow.org
- MXJob.v1.kubeflow.org
runtime:
metricsCollectors:
- kind: StdOut
image: docker.io/kubeflowkatib/file-metrics-collector:latest
- kind: File
image: docker.io/kubeflowkatib/file-metrics-collector:latest
- kind: TensorFlowEvent
image: docker.io/kubeflowkatib/tfevent-metrics-collector:latest
resources:
limits:
memory: 1Gi
suggestions:
- algorithmName: random
image: docker.io/kubeflowkatib/suggestion-hyperopt:latest
- algorithmName: tpe
image: docker.io/kubeflowkatib/suggestion-hyperopt:latest
- algorithmName: grid
image: docker.io/kubeflowkatib/suggestion-optuna:latest
- algorithmName: hyperband
image: docker.io/kubeflowkatib/suggestion-hyperband:latest
- algorithmName: bayesianoptimization
image: docker.io/kubeflowkatib/suggestion-skopt:latest
- algorithmName: cmaes
image: docker.io/kubeflowkatib/suggestion-goptuna:latest
- algorithmName: sobol
image: docker.io/kubeflowkatib/suggestion-goptuna:latest
- algorithmName: multivariate-tpe
image: docker.io/kubeflowkatib/suggestion-optuna:latest
- algorithmName: enas
image: docker.io/kubeflowkatib/suggestion-enas:latest
resources:
limits:
memory: 200Mi
- algorithmName: darts
image: docker.io/kubeflowkatib/suggestion-darts:latest
- algorithmName: pbt
image: docker.io/kubeflowkatib/suggestion-pbt:latest
persistentVolumeClaimSpec:
accessModes:
- ReadWriteMany
resources:
requests:
storage: 5Gi
earlyStoppings:
- algorithmName: medianstop
image: docker.io/kubeflowkatib/earlystopping-medianstop:latest
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,6 @@ resources:
- ../../components/cert-generator/
# Katib webhooks.
- ../../components/webhook/
# Katib Config.
- ../../components/katib-config/
images:
- name: docker.io/kubeflowkatib/katib-controller
newName: docker.io/kubeflowkatib/katib-controller
Expand All @@ -39,3 +37,10 @@ secretGenerator:
- name: katib-mysql-secrets
envs:
- secrets.env
configMapGenerator:
- name: katib-config
behavior: create
files:
- katib-config.yaml
options:
disableNameSuffixHash: true
32 changes: 15 additions & 17 deletions manifests/v1beta1/installs/katib-leader-election/katib-config.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
# This KatibConfig is mostly same as https://github.com/kubeflow/katib/manifests/v1beta1/components/katib-config/katib-config.yaml.
# Only `.init.controller.enableLeaderElection` field is different.
---
apiVersion: config.kubeflow.org/v1beta1
kind: KatibConfig
Expand All @@ -17,40 +15,40 @@ init:
runtime:
metricsCollectors:
- kind: StdOut
image: docker.io/kubeflowkatib/file-metrics-collector:$(KATIB_VERSION)
image: docker.io/kubeflowkatib/file-metrics-collector:latest
- kind: File
image: docker.io/kubeflowkatib/file-metrics-collector:$(KATIB_VERSION)
image: docker.io/kubeflowkatib/file-metrics-collector:latest
- kind: TensorFlowEvent
image: docker.io/kubeflowkatib/tfevent-metrics-collector:$(KATIB_VERSION)
image: docker.io/kubeflowkatib/tfevent-metrics-collector:latest
resources:
limits:
memory: 1Gi
suggestions:
- algorithmName: random
image: docker.io/kubeflowkatib/suggestion-hyperopt:$(KATIB_VERSION)
image: docker.io/kubeflowkatib/suggestion-hyperopt:latest
- algorithmName: tpe
image: docker.io/kubeflowkatib/suggestion-hyperopt:$(KATIB_VERSION)
image: docker.io/kubeflowkatib/suggestion-hyperopt:latest
- algorithmName: grid
image: docker.io/kubeflowkatib/suggestion-optuna:$(KATIB_VERSION)
image: docker.io/kubeflowkatib/suggestion-optuna:latest
- algorithmName: hyperband
image: docker.io/kubeflowkatib/suggestion-hyperband:$(KATIB_VERSION)
image: docker.io/kubeflowkatib/suggestion-hyperband:latest
- algorithmName: bayesianoptimization
image: docker.io/kubeflowkatib/suggestion-skopt:$(KATIB_VERSION)
image: docker.io/kubeflowkatib/suggestion-skopt:latest
- algorithmName: cmaes
image: docker.io/kubeflowkatib/suggestion-goptuna:$(KATIB_VERSION)
image: docker.io/kubeflowkatib/suggestion-goptuna:latest
- algorithmName: sobol
image: docker.io/kubeflowkatib/suggestion-goptuna:$(KATIB_VERSION)
image: docker.io/kubeflowkatib/suggestion-goptuna:latest
- algorithmName: multivariate-tpe
image: docker.io/kubeflowkatib/suggestion-optuna:$(KATIB_VERSION)
image: docker.io/kubeflowkatib/suggestion-optuna:latest
- algorithmName: enas
image: docker.io/kubeflowkatib/suggestion-enas:$(KATIB_VERSION)
image: docker.io/kubeflowkatib/suggestion-enas:latest
resources:
limits:
memory: 200Mi
- algorithmName: darts
image: docker.io/kubeflowkatib/suggestion-darts:$(KATIB_VERSION)
image: docker.io/kubeflowkatib/suggestion-darts:latest
- algorithmName: pbt
image: docker.io/kubeflowkatib/suggestion-pbt:$(KATIB_VERSION)
image: docker.io/kubeflowkatib/suggestion-pbt:latest
persistentVolumeClaimSpec:
accessModes:
- ReadWriteMany
Expand All @@ -59,4 +57,4 @@ runtime:
storage: 5Gi
earlyStoppings:
- algorithmName: medianstop
image: docker.io/kubeflowkatib/earlystopping-medianstop:$(KATIB_VERSION)
image: docker.io/kubeflowkatib/earlystopping-medianstop:latest
59 changes: 59 additions & 0 deletions manifests/v1beta1/installs/katib-openshift/katib-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
---
apiVersion: config.kubeflow.org/v1beta1
kind: KatibConfig
init:
controller:
webhookPort: 8443
trialResources:
- Job.v1.batch
- TFJob.v1.kubeflow.org
- PyTorchJob.v1.kubeflow.org
- MPIJob.v1.kubeflow.org
- XGBoostJob.v1.kubeflow.org
- MXJob.v1.kubeflow.org
runtime:
metricsCollectors:
- kind: StdOut
image: docker.io/kubeflowkatib/file-metrics-collector:latest
- kind: File
image: docker.io/kubeflowkatib/file-metrics-collector:latest
- kind: TensorFlowEvent
image: docker.io/kubeflowkatib/tfevent-metrics-collector:latest
resources:
limits:
memory: 1Gi
suggestions:
- algorithmName: random
image: docker.io/kubeflowkatib/suggestion-hyperopt:latest
- algorithmName: tpe
image: docker.io/kubeflowkatib/suggestion-hyperopt:latest
- algorithmName: grid
image: docker.io/kubeflowkatib/suggestion-optuna:latest
- algorithmName: hyperband
image: docker.io/kubeflowkatib/suggestion-hyperband:latest
- algorithmName: bayesianoptimization
image: docker.io/kubeflowkatib/suggestion-skopt:latest
- algorithmName: cmaes
image: docker.io/kubeflowkatib/suggestion-goptuna:latest
- algorithmName: sobol
image: docker.io/kubeflowkatib/suggestion-goptuna:latest
- algorithmName: multivariate-tpe
image: docker.io/kubeflowkatib/suggestion-optuna:latest
- algorithmName: enas
image: docker.io/kubeflowkatib/suggestion-enas:latest
resources:
limits:
memory: 200Mi
- algorithmName: darts
image: docker.io/kubeflowkatib/suggestion-darts:latest
- algorithmName: pbt
image: docker.io/kubeflowkatib/suggestion-pbt:latest
persistentVolumeClaimSpec:
accessModes:
- ReadWriteMany
resources:
requests:
storage: 5Gi
earlyStoppings:
- algorithmName: medianstop
image: docker.io/kubeflowkatib/earlystopping-medianstop:latest
Loading

0 comments on commit 38de902

Please sign in to comment.