starling.models.vae.KLDWeightScheduler

class KLDWeightScheduler[source]

Bases: object

Methods

__init__

configure

Configure the scheduler with training step information

get_weight

Get current KLD weight for a given step (or max weight if no warmup)

Attributes

current_weight

Get the current KLD weight

max_weight

Get the maximum KLD weight

__init__(max_weight: float, warmup_fraction: float = None, scheduler_type='cyclical')[source]
configure(total_training_steps: int)[source]

Configure the scheduler with training step information

get_weight(step=None) float[source]

Get current KLD weight for a given step (or max weight if no warmup)

property max_weight

Get the maximum KLD weight

property current_weight

Get the current KLD weight