Skip to content

Join an existing Weights and Biases sweep, as a new agent¤

Join an existing Weights and Biases sweep, as a new agent.

parse_arguments() ¤

Parse command line arguments.

Returns:

Type Description
Namespace

argparse.Namespace: Parsed command line arguments.

Source code in sparse_autoencoder/train/join_sweep.py
 7
 8
 9
10
11
12
13
14
15
16
17
def parse_arguments() -> argparse.Namespace:
    """Parse command line arguments.

    Returns:
        argparse.Namespace: Parsed command line arguments.
    """
    parser = argparse.ArgumentParser(description="Join an existing W&B sweep.")
    parser.add_argument(
        "--id", type=str, default=None, help="Sweep ID for the existing sweep.", required=True
    )
    return parser.parse_args()

run() ¤

Run the join_sweep script.

Source code in sparse_autoencoder/train/join_sweep.py
20
21
22
23
24
def run() -> None:
    """Run the join_sweep script."""
    args = parse_arguments()

    sweep(sweep_id=args.id)