docstr: Downloads all artifacts from a run.
  
  Args:
      run:
          Run from which to download artifacts.
      output_dir:
          Output directory where artifacts will be saved.
      timeout:
          Timeout in seconds after which an artifact download is interrupted.
  
  Examples:
      >>> # schedule run
      >>> scheduled_run_id = client.schedule_compute_worker_run(...)
      >>>
      >>> # wait until run completed
      >>> for run_info in client.compute_worker_run_info_generator(scheduled_run_id=scheduled_run_id):
      >>>     pass
      >>>
      >>> # download artifacts
      >>> run = client.get_compute_worker_run_from_scheduled_run(scheduled_run_id=scheduled_run_id)
      >>> client.download_compute_worker_run_artifacts(run=run, output_dir="my_run/artifacts")
docstr_tok: ["Downloads","all","artifacts","from","a","run",".","Args",":","run",":","Run","from","which","to","download","artifacts",".","output_dir",":","Output","directory","where","artifacts","will","be","saved",".","timeout",":","Timeout","in","seconds","after","which","an","artifact","download","is","interrupted",".","Examples",":",">",">",">","#","schedule","run",">",">",">","scheduled_run_id","=","client.schedule_compute_worker_run","(","...",")",">",">",">",">",">",">","#","wait","until","run","completed",">",">",">","for","run_info","in","client.compute_worker_run_info_generator","(","scheduled_run_id=scheduled_run_id",")",":",">",">",">","pass",">",">",">",">",">",">","#","download","artifacts",">",">",">","run","=","client.get_compute_worker_run_from_scheduled_run","(","scheduled_run_id=scheduled_run_id",")",">",">",">","client.download_compute_worker_run_artifacts","(","run=run",",","output_dir=","''","my_run\/artifacts","''",")"]
code: def download_compute_worker_run_artifacts(
      self,
      run: DockerRunData,
      output_dir: str,
      timeout: int = 60,
  ) -> None:
      """Downloads all artifacts from a run.
  
      Args:
          run:
              Run from which to download artifacts.
          output_dir:
              Output directory where artifacts will be saved.
          timeout:
              Timeout in seconds after which an artifact download is interrupted.
  
      Examples:
          >>> # schedule run
          >>> scheduled_run_id = client.schedule_compute_worker_run(...)
          >>>
          >>> # wait until run completed
          >>> for run_info in client.compute_worker_run_info_generator(scheduled_run_id=scheduled_run_id):
          >>>     pass
          >>>
          >>> # download artifacts
          >>> run = client.get_compute_worker_run_from_scheduled_run(scheduled_run_id=scheduled_run_id)
          >>> client.download_compute_worker_run_artifacts(run=run, output_dir="my_run/artifacts")
  
      """
      if run.artifacts is None:
          return
      for artifact in run.artifacts:
          self._download_compute_worker_run_artifact(
              run_id=run.id,
              artifact_id=artifact.id,
              output_path=os.path.join(output_dir, artifact.file_name),
              timeout=timeout,
          )
  
file_path: lightly/lightly/api/api_workflow_artifacts.py
imports: import os
  import warnings
  from lightly.api import download
  from lightly.openapi_generated.swagger_client.models import DockerRunArtifactData, DockerRunArtifactType, DockerRunData
label_desc: Use image node_id 1 for calling the _ArtifactsMixin obj's underlying member method code with example usage: obj.download_compute_worker_run_artifacts(run, output_dir, timeout) without return types