Skip to content

Commit

Permalink
chore: fix after pkg upgrade
Browse files Browse the repository at this point in the history
  • Loading branch information
yathomasi committed Jun 18, 2024
1 parent 0beb504 commit 70a271d
Show file tree
Hide file tree
Showing 151 changed files with 544 additions and 687 deletions.
6 changes: 5 additions & 1 deletion .eslintrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,9 @@
"parserOptions": {
"ecmaFeatures": {
"jsx": true
}
},
"ecmaVersion": "latest",
"sourceType": "module"
},
"env": {
"browser": true,
Expand All @@ -24,6 +26,8 @@
}
},
"rules": {
"react/jsx-uses-react": "off",
"react/react-in-jsx-scope": "off",
"@typescript-eslint/naming-convention": [
"error",
{
Expand Down
11 changes: 5 additions & 6 deletions content/docs/api-reference/artifacts_show.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,17 +14,16 @@ def artifacts_show(

<admon type="tip">

If you have a DVC Studio project configured with your [remote storage
credentials], you may also use the DVC Studio [REST API] to programmatically
access artifacts. It does not require the client to have any credentials other
than the DVC Studio [client access token] and does not require DVC to be
installed.
If you have a DVC Studio project configured with your [remote
storage credentials], you may also use the DVC Studio [REST API] to programmatically
access artifacts. It does not require the client to have any credentials other than
the DVC Studio [client access token] and does not require DVC to be installed.

</admon>

## Usage:

```py:
```py
import dvc.api

artifact = dvc.api.artifacts_show(
Expand Down
22 changes: 10 additions & 12 deletions content/docs/api-reference/get_url.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,13 +29,13 @@ resource_url = dvc.api.get_url(
## Description

Returns the URL string of the storage location (in a [DVC remote] where a target
file or directory, specified by its `path` in a `repo` (<abbr>DVC
project</abbr>), is stored.
file or directory, specified by its `path` in a `repo` (<abbr>DVC project</abbr>),
is stored.

The URL is formed by reading the project's [remote configuration] and the
`dvc.yaml` or `.dvc` file where the given `path` is found (`outs` field). The
schema of the URL returned depends on the [storage type] of the `remote` (see
the [Parameters](#parameters) section).
The URL is formed by reading the project's [remote configuration] and the `dvc.yaml`
or `.dvc` file where the given `path` is found (`outs` field). The schema of the
URL returned depends on the [storage type] of the `remote` (see the
[Parameters](#parameters) section).

If the target is a directory, the returned URL will end in `.dir`. Refer to
[Structure of cache directory] and `dvc add` to learn more about how DVC handles
Expand Down Expand Up @@ -79,13 +79,11 @@ appropriate library, such as [`boto3`] or [`paramiko`].
walking up from the current working directory tree).

- `rev` - Git commit (any [revision](https://git-scm.com/docs/revisions) such as
a branch or tag name, commit hash, or [experiment name]). If `repo` is not a
Git repo, this option is ignored. _Default_: `None` (current working tree will
be used)
a branch or tag name, commit hash, or [experiment name]). If `repo` is not a Git
repo, this option is ignored. _Default_: `None` (current working tree will be used)

- `remote` - name of the [DVC remote] to use to form the returned URL string.
_Default_: The [default remote](/doc/command-reference/remote/default) of
`repo` is used.
- `remote` - name of the [DVC remote] to use to form the returned URL string. _Default_:
The [default remote](/doc/command-reference/remote/default) of `repo` is used.

- `remote_config` - dictionary of options to pass to the DVC remote. This can be
used to, for example, provide credentials to the `remote`.
Expand Down
30 changes: 15 additions & 15 deletions content/docs/api-reference/open.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@ with dvc.api.open(
## Description

Open a data or model file tracked in a <abbr>DVC project</abbr> and generate a
corresponding [file object]. The file can be tracked by DVC (as an
<abbr>output</abbr>) or by Git.
corresponding [file object]. The file can be tracked by DVC (as an <abbr>output</abbr>)
or by Git.

[file object]: https://docs.python.org/3/glossary.html#term-file-object

Expand All @@ -38,18 +38,18 @@ corresponding [file object]. The file can be tracked by DVC (as an
The exact type of file object depends on the `mode` used. For more details,
please refer to Python's [`open()`] built-in, which is used under the hood.

This function makes a direct connection to [remote storage], so the file
contents can be streamed. Your code can process the data [buffer] as it's
streamed, which optimizes memory usage.
This function makes a direct connection to [remote storage], so the file contents
can be streamed. Your code can process the data [buffer] as it's streamed, which
optimizes memory usage.

[`open()`]: https://docs.python.org/3/library/functions.html#open
[remote storage]: /doc/user-guide/data-management/remote-storage
[buffer]: https://docs.python.org/3/c-api/buffer.html

</admon>

`dvc.api.open()` may only be used as a [context manager] (using the `with`
keyword, as shown in the examples).
`dvc.api.open()` may only be used as a [context manager] (using the `with` keyword,
as shown in the examples).

[context manager]:
https://www.python.org/dev/peps/pep-0343/#context-managers-in-the-standard-library
Expand All @@ -72,12 +72,12 @@ call – no _context manager_ involved. Neither function utilizes disc space.
(the current working directory tree is walked up to find it).

- `rev` - Git commit (any [revision] such as a branch or tag name, commit hash,
or [experiment name]). If `repo` is not a Git repo, this option is ignored.
_Default_: `None` (current working tree will be used)
or [experiment name]). If `repo` is not a Git repo, this option is ignored. _Default_:
`None` (current working tree will be used)

- `remote` - name of the [DVC remote] to look for the target data. _Default_:
The [default remote] of `repo` is used if a `remote` argument is not given.
For local projects, the <abbr>cache</abbr> is tried before the default remote.
- `remote` - name of the [DVC remote] to look for the target data. _Default_: The
[default remote] of `repo` is used if a `remote` argument is not given. For
local projects, the <abbr>cache</abbr> is tried before the default remote.

- `remote_config` - dictionary of options to pass to the DVC remote. This can be
used to, for example, provide credentials to the `remote`.
Expand Down Expand Up @@ -186,9 +186,9 @@ directory tree, and look for the file contents of `clean.csv` in its local
## Example: Choose a specific remote as the data source
Sometimes we may want to choose a specific [remote storage] as source, for
example if the `repo` has no default remote set. This can be done by providing a
`remote` argument:
Sometimes we may want to choose a specific [remote storage] as source, for example
if the `repo` has no default remote set. This can be done by providing a `remote`
argument:
```py
import dvc.api
Expand Down
10 changes: 5 additions & 5 deletions content/docs/api-reference/read.md
Original file line number Diff line number Diff line change
Expand Up @@ -63,12 +63,12 @@ Python's [`open()`] built-in, which is used under the hood.
(the current working directory tree is walked up to find it).

- `rev` - Git commit (any [revision] such as a branch or tag name, commit hash,
or [experiment name]). If `repo` is not a Git repo, this option is ignored.
_Default_: `None` (current working tree will be used)
or [experiment name]). If `repo` is not a Git repo, this option is ignored. _Default_:
`None` (current working tree will be used)

- `remote` - name of the [DVC remote] to look for the target data. _Default_:
The [default remote] of `repo` is used if a `remote` argument is not given.
For local projects, the <abbr>cache</abbr> is tried before the default remote.
- `remote` - name of the [DVC remote] to look for the target data. _Default_: The
[default remote] of `repo` is used if a `remote` argument is not given. For
local projects, the <abbr>cache</abbr> is tried before the default remote.

- `remote_config` - dictionary of options to pass to the DVC remote. This can be
used to, for example, provide credentials to the `remote`.
Expand Down
12 changes: 6 additions & 6 deletions content/docs/command-reference/artifacts/get.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,12 +39,12 @@ addressed in the form `path/to/dvc.yaml:artifact_name` or
`path/to:artifact_name` (where `dvc.yaml` is omitted).

`dvc artifacts get` will first try to download artifacts via the DVC Studio
[REST API]. Downloading an artifact using the Studio REST API only requires a
valid DVC Studio [client access token] and a Studio project configured with your
[remote storage credentials]. It does not require the client to have those
credentials. If you do not have a valid DVC Studio token, or the artifact is not
tracked in the model registry, DVC will fall back to its typical method to get
files (see `dvc get`).
[REST API]. Downloading an artifact using the Studio REST API only requires a valid
DVC Studio [client access token] and a Studio project configured with your [remote
storage
credentials]. It does not require the client to have those credentials. If you do
not have a valid DVC Studio token, or the artifact is not tracked in the model registry,
DVC will fall back to its typical method to get files (see `dvc get`).

## Options

Expand Down
22 changes: 11 additions & 11 deletions content/docs/command-reference/checkout.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,14 +45,14 @@ after `git checkout`. See the
for more details.

By default, this command tries not make copies of cached files in the workspace,
using reflinks instead when supported by the file system (refer to [File link
types]). The next linking strategy default value is `copy` though, so unless
other file link types are manually configured in [`cache.type`]), files will be
copied. Keep in mind that having file copies doesn't present much of a negative
impact unless the project uses very large data (several GBs or more). But
leveraging file links is crucial with large files, for example when checking out
a 50Gb file by copying might take a few minutes whereas, with links, restoring
any file size will be almost instantaneous.
using reflinks instead when supported by the file system (refer to [File
link types]). The next linking strategy default value is `copy` though, so
unless other file link types are manually configured in [`cache.type`]), files
will be copied. Keep in mind that having file copies doesn't present much of a
negative impact unless the project uses very large data (several GBs or more).
But leveraging file links is crucial with large files, for example when checking
out a 50Gb file by copying might take a few minutes whereas, with links,
restoring any file size will be almost instantaneous.

[File link types]:
/doc/user-guide/data-management/large-dataset-optimization#file-link-types-for-the-dvc-cache
Expand All @@ -68,9 +68,9 @@ such a case, `dvc checkout` prints a warning message. It also lists the partial
progress made by the checkout.

There are two methods to restore a file missing from the cache, depending on the
situation. In some cases, the data can be pulled from [remote storage] using
`dvc pull`. In other cases, the [pipeline] must be reproduced (using
`dvc repro`) to regenerate its outputs.
situation. In some cases, the data can be pulled from [remote storage] using `dvc pull`.
In other cases, the [pipeline] must be reproduced (using `dvc repro`) to regenerate
its outputs.

[remote storage]: /doc/user-guide/data-management/remote-storage
[pipeline]: /doc/command-reference/dag
Expand Down
4 changes: 2 additions & 2 deletions content/docs/command-reference/commit.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,8 +50,8 @@ Some scenarios for `dvc commit` include:
versions without having to execute stage commands.

- Sometimes after executing a <abbr>stage</abbr>, we realize that not all of its
dependencies or outputs are defined in `dvc.yaml`. It is possible to [add the
missing deps/outs] without having to re-execute stages, and `dvc commit` is
dependencies or outputs are defined in `dvc.yaml`. It is possible to [add
the missing deps/outs] without having to re-execute stages, and `dvc commit` is
needed to finalize the operation (see link).

- It's also possible to execute stage commands by hand (without `dvc repro`), or
Expand Down
6 changes: 3 additions & 3 deletions content/docs/command-reference/config.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,9 @@ positional arguments:

## Description

You can query/set/replace/unset [DVC configuration] options with this command.
It takes a config option `name` (a [config section] and a key, separated by a
dot) and its `value` (any valid alpha-numeric string generally).
You can query/set/replace/unset [DVC configuration] options with this command. It
takes a config option `name` (a [config section] and a key, separated by a dot)
and its `value` (any valid alpha-numeric string generally).

When reading config options (no `value` is given or `--list` is used), the
values are read from a combined set of values from the system, global, project,
Expand Down
4 changes: 2 additions & 2 deletions content/docs/command-reference/data/status.md
Original file line number Diff line number Diff line change
Expand Up @@ -80,8 +80,8 @@ DVC uncommitted changes:
- _Unchanged files_ have no modifications. Only shown if the `--unchanged` flag
is used.

Individual changes to files inside [tracked directories] are not shown by
default but this can be enabled with the `--granular` flag.
Individual changes to files inside [tracked directories] are not shown by default
but this can be enabled with the `--granular` flag.

[committed to dvc]: /doc/command-reference/commit
[tracked directories]: /doc/command-reference/add#adding-entire-directories
Expand Down
4 changes: 2 additions & 2 deletions content/docs/command-reference/diff.md
Original file line number Diff line number Diff line change
Expand Up @@ -123,8 +123,8 @@ $ dvc diff

### Click and expand to set up the example

Let's checkout the [2-track-data] tag, corresponding to the [Data Versioning]
_Get Started_ chapter, right after we added `data.xml` file with DVC:
Let's checkout the [2-track-data] tag, corresponding to the [Data Versioning] _Get
Started_ chapter, right after we added `data.xml` file with DVC:

```cli
$ git checkout 2-track-data
Expand Down
4 changes: 2 additions & 2 deletions content/docs/command-reference/exp/branch.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@ positional arguments:

## Description

Creates a new [Git branch] containing the target `experiment` from the
experiment's baseline (`HEAD` at the time the experiment was run).
Creates a new [Git branch] containing the target `experiment` from the experiment's
baseline (`HEAD` at the time the experiment was run).

If you don't provide a `branch` name, the default one will be based on the name
of the `experiment`.
Expand Down
8 changes: 4 additions & 4 deletions content/docs/command-reference/exp/clean.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,10 @@ Runs housekeeping tasks within the <abbr>DVC repository</abbr>, such as removing
outdated internal experiments queue message files (to reduce disk space and
improve performance).

This is done automatically when running [queued experiments]. Running
`dvc exp clean` manually should not be required for typical use cases, but it
may be needed in the event that a queue worker unexpectedly crashed, or was
forcefully killed by something other than DVC commands.
This is done automatically when running [queued experiments]. Running `dvc exp clean`
manually should not be required for typical use cases, but it may be needed in the
event that a queue worker unexpectedly crashed, or was forcefully killed by something
other than DVC commands.

[queued experiments]:
/doc/user-guide/experiment-management/running-experiments#the-experiments-queue
Expand Down
34 changes: 16 additions & 18 deletions content/docs/command-reference/exp/run.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,9 +55,9 @@ This includes committing any changed data <abbr>dependencies</abbr> to the
Use the `--set-param` (`-S`) option as a shortcut to change
<abbr>parameter</abbr> values [on-the-fly] before running the experiment.

It's possible to [queue experiments] for later execution with the `--queue`
flag. Queued experiments can be run with `dvc queue start` and managed with
other `dvc queue` commands.
It's possible to [queue experiments] for later execution with the `--queue` flag.
Queued experiments can be run with `dvc queue start` and managed with other `dvc queue`
commands.

<admon icon="book">

Expand All @@ -66,9 +66,8 @@ See the [Running Experiments] guide for more details on these features and more.
</admon>

[Review] your experiments with `dvc exp show`. Successful ones can be [made
persistent] by restoring them via `dvc exp branch` or `dvc exp apply` and
committing them to the Git repo. Unnecessary ones can be [cleared] with
`dvc exp remove`.
persistent] by restoring them via `dvc exp branch` or `dvc exp apply` and committing
them to the Git repo. Unnecessary ones can be [cleared] with `dvc exp remove`.

[on-the-fly]: #example-modify-parameters-on-the-fly
[queue experiments]:
Expand All @@ -88,14 +87,13 @@ committing them to the Git repo. Unnecessary ones can be [cleared] with
default) before running the experiment. Use the optional `[<filename>:]`
prefix to use a custom params file.

Valid `<override_pattern>` values can be defined in Hydra's [basic override]
syntax (see [example](#example-modify-parameters-on-the-fly)). Hydra's
[choice] and [range] sweep overrides are also supported, but these require the
`--queue` flag to be provided as well (see
[example](#example-run-a-grid-search)).
Valid `<override_pattern>` values can be defined in Hydra's [basic override] syntax
(see [example](#example-modify-parameters-on-the-fly)). Hydra's [choice] and [range]
sweep overrides are also supported, but these require the `--queue` flag to be
provided as well (see [example](#example-run-a-grid-search)).

- `-n <name>`, `--name <name>` - specify a [unique name] for this experiment. A
default one will be generated otherwise, such as `puffy-daks`.
- `-n <name>`, `--name <name>` - specify a [unique name] for this experiment. A default
one will be generated otherwise, such as `puffy-daks`.

<admon type="tip">

Expand Down Expand Up @@ -175,8 +173,8 @@ committing them to the Git repo. Unnecessary ones can be [cleared] with

- `--pull` - attempts to download missing data as needed. This includes (1)
dependencies of stages to be run, (2) outputs of otherwise unchanged stages to
be skipped, (3) [run cache] for stages to be checked out from cache (unless
`--no-run-cache` is passed).
be skipped, (3) [run cache] for stages to be checked out from cache (unless `--no-run-cache`
is passed).

- `--allow-missing` - skip stages with no other changes than missing data.

Expand Down Expand Up @@ -280,9 +278,9 @@ experiment we just ran (`puffy-daks`).
`dvc exp run --set-param` (`-S`) saves you the need to manually edit a params
file (see `dvc params`) before running an experiment.

This option accepts Hydra's [basic override] syntax. For example, it can
override (`train.epochs=10`), append (`+train.weight_decay=0.01`), or remove
(`~model.dropout`) <abbr>parameters</abbr>:
This option accepts Hydra's [basic override] syntax. For example, it can override
(`train.epochs=10`), append (`+train.weight_decay=0.01`), or remove (`~model.dropout`)
<abbr>parameters</abbr>:

```cli
dvc exp run -S 'prepare.split=0.1' -S 'featurize.max_features=100'
Expand Down
13 changes: 6 additions & 7 deletions content/docs/command-reference/exp/save.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,9 +46,8 @@ use `--include-untracked` (`-I`) on untracked files explicitly (see an
</admon>

[Review] your experiments with `dvc exp show`. Successful ones can be [made
persistent] by restoring them via `dvc exp branch` or `dvc exp apply` and
committing them to the Git repo. Unnecessary ones can be [cleared] with
`dvc exp remove`.
persistent] by restoring them via `dvc exp branch` or `dvc exp apply` and committing
them to the Git repo. Unnecessary ones can be [cleared] with `dvc exp remove`.

[review]: /doc/user-guide/experiment-management/comparing-experiments
[made persistent]:
Expand All @@ -58,8 +57,8 @@ committing them to the Git repo. Unnecessary ones can be [cleared] with

## Options

- `-n <name>`, `--name <name>` - specify a [unique name] for this experiment. A
default one will be generated otherwise, such as `urban-sign`.
- `-n <name>`, `--name <name>` - specify a [unique name] for this experiment. A default
one will be generated otherwise, such as `urban-sign`.

<admon type="tip">

Expand Down Expand Up @@ -123,8 +122,8 @@ Untracked files:

We can inspect results with `dvc metrics show` (or other means) after running
the experiment (in this case we can do so with `dvc repro` since the example
project uses a [DVC pipeline]). We are not quite ready for a Git commit, but we
want to save the results in the repo nonetheless:
project uses a [DVC pipeline]). We are not quite ready for a Git commit, but we want
to save the results in the repo nonetheless:

```cli
dvc exp save --name extra-trees \
Expand Down
Loading

0 comments on commit 70a271d

Please sign in to comment.