diff --git a/check.py b/check.py index b399a7d..dc77d57 100644 --- a/check.py +++ b/check.py @@ -1,6 +1,6 @@ # import matplotlib.patches as patches -from typing import Union from pathlib import Path +from typing import Union import matplotlib.patches as patches import matplotlib.pyplot as plt @@ -46,8 +46,10 @@ def create_circle( ckpt: Union[str, ColorTransformerModel], fname: str, skip: bool = True, **kwargs ): if isinstance(ckpt, str): - import yaml - M = ColorTransformerModel.load_from_checkpoint(ckpt, map_location=lambda storage, loc: storage) + + M = ColorTransformerModel.load_from_checkpoint( + ckpt, map_location=lambda storage, loc: storage + ) else: M = ckpt @@ -152,7 +154,9 @@ if __name__ == "__main__": if len(ckpt) > 0: ckpt = ckpt[-1] print(f"Generating image for checkpoint: {ckpt}") - create_circle(ckpt, fname=name, dpi=args.dpi, figsize=[args.figsize] * 2, roll=False) + create_circle( + ckpt, fname=name, dpi=args.dpi, figsize=[args.figsize] * 2, roll=False + ) else: print(f"No checkpoint found for version {v}") # make_image(ckpt, fname=name + "b", color=False, dpi=args.dpi,) diff --git a/newsearch.py b/newsearch.py index c72cb5b..5f0cf17 100644 --- a/newsearch.py +++ b/newsearch.py @@ -27,7 +27,7 @@ learning_rate_values = [1e-3] # learning_rate_values = [5e-4] # alpha_values = [0, .25, 0.5, 0.75, 1] # alpha = 0 is unsupervised. alpha = 1 is supervised. -alpha_values = [0] +alpha_values = [0.1] # widths = [2**k for k in range(4, 13)] # depths = [1, 2, 4, 8, 16] widths, depths = [512], [4] @@ -80,7 +80,7 @@ python newmain.py fit \ --model.depth {d} \ --model.bias true \ --model.loop true \ ---model.transform tanh \ +--model.transform relu \ --trainer.min_epochs 10 \ --trainer.max_epochs {me} \ --trainer.log_every_n_steps 3 \