credit.pbs
==========

.. py:module:: credit.pbs


Attributes
----------

.. autoapisummary::

   credit.pbs.logger
   credit.pbs.config_file


Functions
---------

.. autoapisummary::

   credit.pbs.launch_script
   credit.pbs.launch_script_mpi


Module Contents
---------------

.. py:data:: logger

.. py:function:: launch_script(config_file, script_path, launch=True)

   Generates and optionally launches a PBS script for a single-node job.

   :param config_file: Path to the YAML configuration file.
   :type config_file: str
   :param script_path: Path to the script that will be executed by the PBS job.
   :type script_path: str
   :param launch: If True, the PBS job will be submitted to the queue. Defaults to True.
   :type launch: bool, optional


.. py:function:: launch_script_mpi(config_file, script_path, launch=True, backend='nccl')

   Generates and optionally launches a PBS script for a multi-node MPI job.

   :param config_file: Path to the YAML configuration file.
   :type config_file: str
   :param script_path: Path to the script that will be executed by the MPI job.
   :type script_path: str
   :param launch: If True, the PBS job will be submitted to the queue. Defaults to True.
   :type launch: bool, optional
   :param backend: Backend to be used for distributed training (e.g., 'nccl'). Defaults to 'nccl'.
   :type backend: str, optional


.. py:data:: config_file
   :value: '../config/vit2d.yml'


