diff --git a/content/docs/cml-with-dvc.md b/content/docs/cml-with-dvc.md index b28b9796..4093f5f3 100644 --- a/content/docs/cml-with-dvc.md +++ b/content/docs/cml-with-dvc.md @@ -46,8 +46,8 @@ jobs: -x actual \ -y predicted \ --show-vega master > vega.json - vl2png vega.json -s 1.5 > plot.png - cml publish --md plot.png >> report.md + vl2png vega.json -s 1.5 > plot-confusion.png + echo '![](./plot-confusion.png)' >> report.md # Publish regularization function diff echo "### Effects of regularization" >> report.md @@ -55,10 +55,10 @@ jobs: --target estimators.csv \ -x Regularization \ --show-vega master > vega.json - vl2png vega.json -s 1.5 > plot.png - cml publish --md plot.png >> report.md + vl2png vega.json -s 1.5 > plot-diff.png + echo '![](./plot-diff.png)' >> report.md - cml send-comment report.md + cml comment create --publish report.md ``` See the [example repository](https://github.com/iterative/cml_dvc_case) for @@ -127,7 +127,7 @@ Networking cost and transfer time can also be reduced using an appropriate ```cli -$ cml runner \ +$ cml runner launch \ --cloud=aws \ --cloud-region=us-west \ --cloud-type=m+t4 \ @@ -139,7 +139,7 @@ $ cml runner \ ```cli -$ cml runner \ +$ cml runner launch \ --cloud=gcp \ --cloud-region=us-west \ --cloud-type=m+t4 \ diff --git a/content/docs/ref/send-github-check.md b/content/docs/ref/check.md similarity index 86% rename from content/docs/ref/send-github-check.md rename to content/docs/ref/check.md index 94ba0530..cf747ec2 100644 --- a/content/docs/ref/send-github-check.md +++ b/content/docs/ref/check.md @@ -1,10 +1,10 @@ -# Command Reference: `send-github-check` +# Command Reference: `check` ```usage -cml send-github-check [options] +cml check create [options] ``` -Similar to [`send-comment`](/doc/ref/send-comment), but using GitHub's +Similar to [`comment create`](/doc/ref/comment#create), but using GitHub's [checks interface](https://docs.github.com/en/rest/reference/checks). ## Options diff --git a/content/docs/ref/send-comment.md b/content/docs/ref/comment.md similarity index 56% rename from content/docs/ref/send-comment.md rename to content/docs/ref/comment.md index 08ac39bd..416e486b 100644 --- a/content/docs/ref/send-comment.md +++ b/content/docs/ref/comment.md @@ -1,22 +1,33 @@ -# Command Reference: `send-comment` +# Command Reference: `comment` + +## create + +Post a Markdown report as a comment on a commit or pull/merge request. ```usage -cml send-comment [options] +cml comment create [options] ``` -Post a Markdown report as a comment on a commit or pull/merge request. +## update + +Update the last CML comment instead of creating a new one. If no previous +comment is found, create a new one. + +```usage +cml comment update [options] +``` -If there's an associated pull/merge request, consider adding the `--pr` and -`--update` flags. +If there's an associated pull/merge request, consider using `update` with the +`--pr` flag. -If `cml pr` was used earlier in the workflow, use `--commit-sha=HEAD` to post -comments to the new PR if desired. +If [`cml pr`](/doc/ref/pr) was used earlier in the workflow, use +`--commit-sha=HEAD` to post comments to the new PR if desired. @@ -28,11 +39,15 @@ Any [generic option](/doc/ref) in addition to: [Git revision](https://git-scm.com/docs/gitrevisions) linked to this comment [default: `HEAD`]. - `--pr`: Post to an existing PR/MR associated with the specified commit. -- `--update`: Update the last CML comment (if any) instead of creating a new - one. -- `--rm-watermark`: Don't inject a watermark into the comment. Will break some - CML functionality (such as `--update`) which needs to distinguish CML reports - from other comments. +- `--watch`: Watch for changes and automatically update the comment (doesn't + exit, consider + [appending `&` to run in the background]()). +- `--publish`: Upload any local images found in the Markdown report. +- `--publish-url=`: Self-hosted image server URL [default: + `https://asset.cml.dev`], see + [minroud-s3](https://github.com/iterative/minroud-s3). +- `--native`: Uses `--driver`'s native capabilities to `--publish` assets + instead of `--publish-url` (not available on `--driver=github`). ## FAQs and Known Issues @@ -42,8 +57,8 @@ Any [generic option](/doc/ref) in addition to: This [error](https://github.community/t/comment-api-does-not-describe-commit-id-has-been-locked/159853/2) - is caused by using the default GitHub token with `cml send-comment --update`. - Use a + is caused by using the default GitHub token with + [`cml comment update`](#update). Use a [personal access token (PAT)](/doc/self-hosted-runners?tab=GitHub#personal-access-token) instead. diff --git a/content/docs/ref/index.md b/content/docs/ref/index.md index af49d706..51e83752 100644 --- a/content/docs/ref/index.md +++ b/content/docs/ref/index.md @@ -4,13 +4,13 @@ All CML commands support the following options: -- `--repo=`: Repository (or Organization) to be used [default: +- `--repo=`: Repository (or Organization) URL or slug [default: *inferred from environment*]. - `--token=`: [Personal/project access token](https://cml.dev/doc/self-hosted-runners#personal-access-token) to be used [default: *inferred from environment*]. -- `--log={error,warn,info,debug}`: Maximum log level [default: `info`]. -- `--driver={github,gitlab,bitbucket}`: CI provider where the repository is - hosted [default: *inferred from environment*]. +- `--log={error,warn,info,debug}`: Logging verbosity [default: `info`]. +- `--driver={github,gitlab,bitbucket}`: CI provider where workflows are run + [default: *inferred from environment*]. - `--help`: Show help. - `--version`: Show version number. diff --git a/content/docs/ref/pr.md b/content/docs/ref/pr.md index 7f6dc235..88fdd607 100644 --- a/content/docs/ref/pr.md +++ b/content/docs/ref/pr.md @@ -1,11 +1,12 @@ # Command Reference: `pr` ```usage -cml pr [options] ... +cml pr create [options] ... ``` Commit specified files to a new branch and create a pull request. If sending a -report afterwards, consider using `cml send-comment --pr --update`. +report afterwards, consider using +[`cml comment update --pr`](/doc/ref/comment#update). @@ -45,14 +46,14 @@ Any [generic option](/doc/ref) in addition to: ### Commit all files in current working directory ```cli -$ cml pr . +$ cml pr create . ``` ### Automatically merge pull requests ```cli $ date > output.txt -$ cml pr --auto-merge output.txt +$ cml pr create --merge output.txt # or --squash/--rebase ``` The `--merge`, `--rebase`, and `--squash` options enable @@ -65,7 +66,7 @@ checks isn't supported, `cml pr` will try to merge the pull request immediately. ## Command internals ```cli -$ cml pr "**/*.py" "**/*.json" +$ cml pr create "**/*.py" "**/*.json" ``` is roughly equivalent to: diff --git a/content/docs/ref/publish.md b/content/docs/ref/publish.md index 7df18063..8567aac1 100644 --- a/content/docs/ref/publish.md +++ b/content/docs/ref/publish.md @@ -4,7 +4,8 @@ cml publish [options] ``` -Publicly host an image for displaying in a CML report. +Publicly host an image for displaying in a CML report. Used internally by +[`cml comment {create,update} --publish`](/doc/ref/comment). ## Options @@ -17,8 +18,6 @@ Any [generic option](/doc/ref) in addition to: [default: *inferred from content*]. - `--native`: Uses CI provider's native storage instead of CML's. [Not available on GitHub](https://github.com/iterative/cml/wiki/Backend-Supported-Features). -- `--rm-watermark`: Don't inject a watermark into the comment. Will break some - CML functionality which needs to distinguish CML reports from other comments. - `--url=<...>`: Use a custom storage URL instead of asset.cml.dev. See [`minroud-s3`](https://github.com/iterative/minroud-s3) for a reference implementation. diff --git a/content/docs/ref/runner.md b/content/docs/ref/runner.md index ef452a66..c4a0f7c8 100644 --- a/content/docs/ref/runner.md +++ b/content/docs/ref/runner.md @@ -1,7 +1,7 @@ # Command Reference: `runner` ```usage -cml runner [options] +cml runner launch [options] ``` Starts a [runner](/doc/self-hosted-runners) (either via any supported cloud @@ -99,7 +99,7 @@ An AWS ARN to an instance-profile: - `arn:aws:iam::1234567890:instance-profile/dvc-s3-access` ```cli -$ cml runner \ +$ cml runner launch \ --cloud-permission-set=arn:aws:iam::1234567890:instance-profile/dvc-s3-access \ ... ``` @@ -114,7 +114,7 @@ A GCP service account email & - `my-sa@myproject.iam.gserviceaccount.com,scopes=storage-rw` ```cli -$ cml runner \ +$ cml runner launch \ --cloud-permission-set=my-sa@myproject.iam.gserviceaccount.com,scopes=storage-rw,datastore \ ... ``` @@ -297,7 +297,7 @@ instance and exiting with an error. For example: ```cli -$ cml runner \ +$ cml runner launch \ --cloud-startup-script=IyEvYmluL2Jhc2gKCmVjaG8gImhlbGxvIHdvcmxkIgo= \ ... ``` @@ -314,7 +314,7 @@ This can be used for debugging, for example allowing SSH access for a GitHub user: ```cli -$ cml runner \ +$ cml runner launch \ --cloud-startup-script=$(echo 'echo "$(curl https://github.com/${{ github.actor }}.keys)" >> /home/ubuntu/.ssh/authorized_keys' | base64 -w 0) \ ... ``` @@ -358,7 +358,7 @@ Azure. `cml runner` command: ```cli - $ cml runner --cloud=... --cloud-ssh-private="$(cat key.pem)" + $ cml runner launch --cloud=... --cloud-ssh-private="$(cat key.pem)" ``` 3. Access the instance from your local system by using the generated key as an diff --git a/content/docs/ref/tensorboard-dev.md b/content/docs/ref/tensorboard.md similarity index 71% rename from content/docs/ref/tensorboard-dev.md rename to content/docs/ref/tensorboard.md index a895ab5c..4bcf710d 100644 --- a/content/docs/ref/tensorboard-dev.md +++ b/content/docs/ref/tensorboard.md @@ -1,7 +1,7 @@ -# Command Reference: `tensorboard-dev` +# Command Reference: `tensorboard` ```usage -cml tensorboard-dev [options] +cml tensorboard connect [options] ``` Return a link to a page. @@ -20,11 +20,9 @@ Any [generic option](/doc/ref) in addition to: - `--md`: Produce output in Markdown format (`[title](url)`). - `-t=<...>`, `--title=<...>`: Title for Markdown output [default: *value of `--name`*]. -- `--rm-watermark`: Don't inject a watermark into the comment. Will break some - CML functionality which needs to distinguish CML reports from other comments. ## Examples ```cli -$ cml tensorboard-dev --logdir=./logs --title=Training --md >> report.md +$ cml tensorboard connect --logdir=./logs --title=Training --md >> report.md ``` diff --git a/content/docs/ref/workflow.md b/content/docs/ref/workflow.md new file mode 100644 index 00000000..3e8d1a74 --- /dev/null +++ b/content/docs/ref/workflow.md @@ -0,0 +1,19 @@ +# Command Reference: `workflow` + +```usage +cml workflow rerun [options] +``` + +Rerun a workflow given a Job/Workflow ID. + +## Options + +Any [generic option](/doc/ref) in addition to: + +- `--id`: Job/Workflow ID. + +## Examples + +```cli +$ cml workflow rerun --id=133742 +``` diff --git a/content/docs/self-hosted-runners.md b/content/docs/self-hosted-runners.md index ffbc62fc..eb01deae 100644 --- a/content/docs/self-hosted-runners.md +++ b/content/docs/self-hosted-runners.md @@ -59,7 +59,7 @@ jobs: AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }} AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }} run: | - cml runner \ + cml runner launch \ --cloud=aws \ --cloud-region=us-west \ --cloud-type=p2.xlarge \ @@ -84,8 +84,8 @@ jobs: # Create CML report cat metrics.txt >> report.md - cml publish plot.png --md --title="Confusion Matrix" >> report.md - cml send-comment report.md + echo '![](./plot.png "Confusion Matrix")' >> report.md + cml comment create --publish report.md ``` @@ -96,7 +96,7 @@ deploy-runner: image: iterativeai/cml:0-dvc2-base1 script: - | - cml runner \ + cml runner launch \ --cloud=aws \ --cloud-region=us-west \ --cloud-type=p2.xlarge \ @@ -112,8 +112,8 @@ train-model: - python train.py # Create CML report - cat metrics.txt >> report.md - - cml publish plot.png --md --title="Confusion Matrix" >> report.md - - cml send-comment report.md + - echo '![](./plot.png "Confusion Matrix")' >> report.md + - cml comment create --publish report.md ``` @@ -126,7 +126,7 @@ pipelines: image: iterativeai/cml:0-dvc2-base1 script: - | - cml runner \ + cml runner launch \ --cloud=aws \ --cloud-region=us-west \ --cloud-type=m5.2xlarge \ @@ -141,8 +141,8 @@ pipelines: - python train.py # Create CML report - cat metrics.txt >> report.md - - cml publish plot.png --md --title="Confusion Matrix" >> report.md - - cml send-comment report.md + - echo '![](./plot.png "Confusion Matrix")' >> report.md + - cml comment create --publish report.md ``` @@ -154,7 +154,7 @@ newly-launched instance. See [Environment Variables](#environment-variables) below for details on the `secrets` required. 🎉 **Note that jobs can use any Docker container!** To use commands such as -`cml send-comment` from a job, the only requirement is to +`cml comment create` from a job, the only requirement is to [have CML installed](/doc/install). ## Docker Images @@ -293,7 +293,7 @@ steps: REPO_TOKEN: ${{ steps.get-token.outputs.token }} run: | ... - cml send-comment report.md + cml comment create report.md ``` Note that the Apps require the following **write** @@ -301,8 +301,8 @@ Note that the Apps require the following **write** - Repository permissions (if used on a per-repo basis) - Administration (`cml runner`) - - Checks (`cml send-github-check`) - - Pull requests (`cml {pr,send-comment}`) + - Checks (`cml check`) + - Pull requests (`cml {pr,comment}`) - Organization permissions (if used on an org) - Self-hosted runners (`cml runner`) @@ -332,7 +332,7 @@ For instance, to use a personal access token: ![](/img/personal_access_token.png) -1. In your GitLab project, navigate to **Settings** → **CI/CD** +2. In your GitLab project, navigate to **Settings** → **CI/CD** → **Variables** → **Add Variable** ![](/img/ci_cd_navigation.png) @@ -441,7 +441,7 @@ on-premise GPU cluster, or any other cloud compute resource as a self-hosted runner. Simply [install CML](/doc/install) and then run: ```cli -$ cml runner \ +$ cml runner launch \ --repo="$REPOSITORY_URL" \ --token="$PERSONAL_ACCESS_TOKEN" \ --labels="local,runner" \ diff --git a/content/docs/sidebar.json b/content/docs/sidebar.json index c90fff67..192371d4 100644 --- a/content/docs/sidebar.json +++ b/content/docs/sidebar.json @@ -43,28 +43,28 @@ "slug": "ci" }, { - "label": "pr", - "slug": "pr" + "label": "runner", + "slug": "runner" }, { - "label": "publish", - "slug": "publish" + "label": "pr", + "slug": "pr" }, { - "label": "runner", - "slug": "runner" + "label": "comment", + "slug": "comment" }, { - "label": "send-comment", - "slug": "send-comment" + "label": "check", + "slug": "check" }, { - "label": "send-github-check", - "slug": "send-github-check" + "label": "workflow", + "slug": "workflow" }, { - "label": "tensorboard-dev", - "slug": "tensorboard-dev" + "label": "tensorboard", + "slug": "tensorboard" } ] }, diff --git a/content/docs/start/bitbucket.md b/content/docs/start/bitbucket.md index 81e30191..9c1956fa 100644 --- a/content/docs/start/bitbucket.md +++ b/content/docs/start/bitbucket.md @@ -13,8 +13,7 @@ all the supported CI systems. [these instructions](https://cml.dev/doc/self-hosted-runners?tab=Bitbucket#personal-access-token) to configure a Bitbucket token for CML. -3. ⚠️ Follow - [these instructions](https://cml.dev/doc/ref/send-comment#bitbucket) to +3. ⚠️ Follow [these instructions](https://cml.dev/doc/ref/comment#bitbucket) to enable the Pull Request Commit Links application. @@ -43,8 +42,8 @@ $ git clone https://bitbucket.org//example-cml - python train.py - cat metrics.txt >> report.md - - cml publish plot.png --md >> report.md - - cml send-comment report.md + - echo '![](./plot.png)' >> report.md + - cml comment create --publish report.md ``` 5. In your text editor, open `train.py` and modify line 15 to `depth = 5`. @@ -69,7 +68,8 @@ $ git clone https://bitbucket.org//example-cml Shortly, you should see a comment appear in the Pull Request with your CML - report. This is a result of the `cml send-comment` command in your workflow. + report. This is a result of the `cml comment create` command in your + workflow. ![](/img/bitbucket_cml_first_report.png) diff --git a/content/docs/start/github.md b/content/docs/start/github.md index 4063faf6..0cf296fb 100644 --- a/content/docs/start/github.md +++ b/content/docs/start/github.md @@ -44,8 +44,8 @@ $ cd example_cml python train.py cat metrics.txt >> report.md - cml publish plot.png --md >> report.md - cml send-comment report.md + echo '![](./plot.png)' >> report.md + cml comment create --publish report.md ``` 3. In your text editor, open `train.py` and modify line 15 to `depth = 5`. @@ -70,7 +70,8 @@ $ cd example_cml ![](/img/make_pr.png) Shortly, you should see a comment appear in the Pull Request with your CML - report. This is a result of the `cml send-comment` command in your workflow. + report. This is a result of the `cml comment create` command in your + workflow. ![](/img/cml_first_report.png) @@ -100,8 +101,8 @@ Docker container. This action gives you: -- Commands like `cml publish` and `cml send-comment` for publishing data - visualization and metrics from your CI workflow as comments in a pull request. +- Commands like `cml comment create` for publishing data visualization and + metrics from your CI workflow as comments in a pull request. - `cml runner`, a command that enables workflows to provision cloud and on-premise computing resources for training models - The freedom 🦅 to mix and match CML with your favorite data science tools and @@ -159,6 +160,6 @@ steps: python train.py echo "# My first CML report" >> report.md - cml publish plot.png --md --title="Confusion Matrix" >> report.md - cml send-comment report.md + echo '![](./plot.png "Confusion Matrix")' >> report.md + cml comment create --publish report.md ``` diff --git a/content/docs/start/gitlab.md b/content/docs/start/gitlab.md index ba66af7d..cf864e7b 100644 --- a/content/docs/start/gitlab.md +++ b/content/docs/start/gitlab.md @@ -39,8 +39,8 @@ $ cd example_cml - python train.py - cat metrics.txt >> report.md - - cml publish plot.png --md >> report.md - - cml send-comment report.md + - echo '![](./plot.png)' >> report.md + - cml comment create --publish report.md ``` 4. In your text editor, open `train.py` and modify line 15 to `depth = 5`. @@ -72,7 +72,7 @@ $ cd example_cml Continue and submit the Merge Request. Shortly, you should see a comment appear in the Merge Request with your CML report. This is a result of the - `cml send-comment` command in your workflow. + `cml comment create` command in your workflow. ![](/img/cml_start_gitlab_end.png) diff --git a/content/docs/usage.md b/content/docs/usage.md index e399a0ea..1d6d68d2 100644 --- a/content/docs/usage.md +++ b/content/docs/usage.md @@ -41,7 +41,7 @@ jobs: run: | # Post reports as comments in GitHub PRs cat results.txt >> report.md - cml send-comment report.md + cml comment create report.md ``` The example above generates visual reports in pull requests: @@ -78,8 +78,8 @@ create-CML-report: image: iterativeai/cml:0-dvc2-base1 script: - cat metrics.txt >> report.md - - cml publish plot.png --md >> report.md - - cml send-comment report.md + - echo '![](./plot.png)' >> report.md + - cml comment create --publish report.md ``` ⚠️ You _must_ provide a @@ -121,8 +121,8 @@ pipelines: script: - cat metrics.txt > report.md - echo >> report.md - - cml publish plot.png --md >> report.md - - cml send-comment report.md + - echo '![](./plot.png)' >> report.md + - cml comment create --publish report.md ``` ⚠️ You _must_ provide @@ -155,31 +155,27 @@ publishing Markdown reports to your CI/CD system. ∞ **[`runner`](/doc/ref/runner)**\ Launch a runner hosted by a cloud compute provider or locally on-premise (see [self-hosted runners](/doc/self-hosted-runners))\ -e.g. `cml runner --cloud={aws,azure,gcp,kubernetes} ...` - -∞ **[`publish`](/doc/ref/publish)**\ -Publicly host an image for displaying in a CML report\ -e.g. `cml publish plot.png --md >> report.md` +e.g. `cml runner launch --cloud={aws,azure,gcp,kubernetes} ...` ∞ **[`pr`](/doc/ref/pr)**\ Commit specified files to a new branch and create a pull request\ -e.g. `cml pr "**/*.json" "**/*.py" --md >> report.md` +e.g. `cml pr create "**/*.json" "**/*.py" --md >> report.md` -∞ **[`send-comment`](/doc/ref/send-comment)**\ +∞ **[`comment`](/doc/ref/comment)**\ Post a Markdown report as a commit comment\ -e.g. `cml send-comment report.md` +e.g. `cml comment create report.md` -∞ **[`send-github-check`](/doc/ref/send-github-check)**\ +∞ **[`check`](/doc/ref/check)**\ Post a Markdown report as a GitHub check\ -e.g. `cml send-github-check report.md` +e.g. `cml check create report.md` -∞ **[`tensorboard-dev`](/doc/ref/tensorboard-dev)**\ +∞ **[`tensorboard`](/doc/ref/tensorboard)**\ Return a link to a page\ -e.g. `cml tensorboard-dev --logdir=./logs --md >> report.md` +e.g. `cml tensorboard connect --logdir=./logs --md >> report.md` ### CML Reports -The `cml send-comment` command can be used to post reports. CML reports are +The `cml comment create` command can be used to post reports. CML reports are written in Markdown ([GitHub](https://github.github.com/gfm), [GitLab](https://docs.gitlab.com/ee/user/markdown.html), or [Bitbucket](https://confluence.atlassian.com/bitbucketserver/markdown-syntax-guide-776639995.html) @@ -195,10 +191,11 @@ $ cat results.txt >> report.md ``` 🖼️ **Images** Display images using the markdown or HTML. Note that if an image -is an output of your ML workflow (i.e., it is produced by your workflow), you -will need to use the `cml publish` command to include it a CML report. For -example, if `plot.png` is output by `python train.py`, run: +is an output of your ML workflow (i.e. it is produced by your workflow), you +will need to use the `--publish` option to include it a CML report. For example, +if `plot.png` is output by `python train.py`, run: ```cli -$ cml publish plot.png --md >> report.md +$ echo '![](./plot.png)' >> report.md +$ cml comment create --publish report.md ``` diff --git a/redirects-list.json b/redirects-list.json index e95e5b9a..2d7a129e 100644 --- a/redirects-list.json +++ b/redirects-list.json @@ -6,6 +6,10 @@ "^/doc/start/start-github(/.*)?$ /doc/start/github", "^/doc/start/start-gitlab(/.*)?$ /doc/start/gitlab", + "^/doc/ref/send-github-check(/.*)?$ /doc/ref/check$1 301", + "^/doc/ref/send-comment(/.*)?$ /doc/ref/comment$1 301", + "^/doc/ref/tensorboard-dev(/.*)?$ /doc/ref/tensorboard$1 301", + "^/doc/cml-with-npm(/.*)?$ /doc/install$1 301", "^/(.+)/$ /$1" diff --git a/src/components/pages/Home/UseCasesSection/index.tsx b/src/components/pages/Home/UseCasesSection/index.tsx index e5e6b4fc..e4506f57 100644 --- a/src/components/pages/Home/UseCasesSection/index.tsx +++ b/src/components/pages/Home/UseCasesSection/index.tsx @@ -87,8 +87,8 @@ const UseCasesSection: React.ForwardRefRenderFunction = () => (
- cat metrics.txt >> report.md
-
- cml publish plot.png --md >> report.md
-
- cml send-comment report.md
+
- echo '![](./plot.png)' >> report.md
+
- cml comment create --publish report.md
@@ -133,8 +133,8 @@ const UseCasesSection: React.ForwardRefRenderFunction = () => (
cat metrics.txt >> report.md
-
cml publish plot.png --md >> report.md
-
cml send-comment report.md
+
echo '![](./plot.png)' >> report.md
+
cml comment create --publish report.md
@@ -180,8 +180,8 @@ const UseCasesSection: React.ForwardRefRenderFunction = () => (
--target loss.csv --show-vega master > vega.json
- vl2png vega.json > plot.png
-
- cml publish --md plot.png >> report.md
-
- cml send-comment report.md
+
- echo '![](./plot.png)' >> report.md
+
- cml comment create --publish report.md
@@ -242,8 +242,8 @@ const UseCasesSection: React.ForwardRefRenderFunction = () => (
--target loss.csv --show-vega master > vega.json
vl2png vega.json -s 1.5 > plot.png
-
cml publish --md plot.png >> report.md
-
cml send-comment report.md
+
echo '![](./plot.png)' >> report.md
+
cml comment create --publish report.md
@@ -274,13 +274,13 @@ const UseCasesSection: React.ForwardRefRenderFunction = () => (
script:
- pip install -r requirements.txt
-
- cml tensorboard-dev \
+
- cml tensorboard connect \
--logdir logs \
--name "Go to tensorboard" \
--md >> report.md
-
- cml send-comment report.md
+
- cml comment create report.md
@@ -328,13 +328,13 @@ const UseCasesSection: React.ForwardRefRenderFunction = () => (
pip install -r requirements.txt
-
cml tensorboard-dev \
+
cml tensorboard connect \
--logdir logs \
--name "Go to tensorboard" \
--md >> report.md
-
cml send-comment report.md
+
cml comment create report.md
@@ -370,7 +370,7 @@ const UseCasesSection: React.ForwardRefRenderFunction = () => (
image: iterativeai/cml:0-dvc2-base1
script:
-
- cml runner
+
- cml runner launch
--cloud aws
--cloud-region us-west
--cloud-type t2.micro
@@ -392,8 +392,8 @@ const UseCasesSection: React.ForwardRefRenderFunction = () => (
- echo "## Report from your EC2 Instance" > report.md
- cat metrics.txt >> report.md
-
- cml publish "plot.png" --md >> report.md
-
- cml send-comment report.md
+
- echo '![](./plot.png)' >> report.md
+
- cml comment create --publish report.md
@@ -426,7 +426,7 @@ const UseCasesSection: React.ForwardRefRenderFunction = () => (
AWS_SECRET_ACCESS_KEY: {"${{ secrets.AWS_SECRET_ACCESS_KEY }}"}
run: |
-
cml runner \
+
cml runner launch \
--cloud aws \
--cloud-region us-west \
--cloud-type=t2.micro \
@@ -455,8 +455,8 @@ const UseCasesSection: React.ForwardRefRenderFunction = () => (
echo "## Report from your EC2 Instance" > report.md
cat metrics.txt >> report.md
-
cml publish "plot.png" --md >> report.md
-
cml send-comment report.md
+
echo '![](./plot.png)' >> report.md
+
cml comment create --publish report.md
@@ -488,7 +488,7 @@ const UseCasesSection: React.ForwardRefRenderFunction = () => (
image: iterativeai/cml:0-dvc2-base1
script:
-
- cml runner \
+
- cml runner launch \
--cloud aws \
--cloud-region us-west \
--cloud-type=p2.xlarge \
@@ -521,7 +521,7 @@ const UseCasesSection: React.ForwardRefRenderFunction = () => (
- convert +append final_owl.png master_owl.png out.png
- convert out.png -resize 75% out_shrink.png
- echo "### Workspace vs. Master" >> report.md
-
- cml publish out_shrink.png --md >> report.md
+
- echo '![](./out_shrink.png)' >> report.md
# Report training parameters
- echo "## Training parameter diffs" >> report.md
@@ -532,7 +532,7 @@ const UseCasesSection: React.ForwardRefRenderFunction = () => (
- echo "## GPU info" >> report.md
- cat gpu_info.txt >> report.md
-
- cml send-comment report.md
+
- cml comment create --publish report.md
@@ -566,7 +566,7 @@ const UseCasesSection: React.ForwardRefRenderFunction = () => (
AWS_SECRET_ACCESS_KEY: {"${{ secrets.AWS_SECRET_ACCESS_KEY }}"}
run: |
-
cml runner \
+
cml runner launch \
--cloud aws \
--cloud-region us-west \
--cloud-type=p2.xlarge \
@@ -611,7 +611,7 @@ const UseCasesSection: React.ForwardRefRenderFunction = () => (
convert +append final_owl.png master_owl.png out.png
convert out.png -resize 75% out_shrink.png
echo "### Workspace vs. Main" >> report.md
-
cml publish out_shrink.png --md --title 'compare' >> report.md
+
echo '![](./out_shrink.png "compare")' >> report.md
echo "## Training metrics" >> report.md
dvc params diff master --show-md >> report.md
@@ -620,7 +620,7 @@ const UseCasesSection: React.ForwardRefRenderFunction = () => (
echo "## GPU info" >> report.md
cat gpu_info.txt >> report.md
-
cml send-comment report.md
+
cml comment create --publish report.md