mirror of
https://github.com/fumiama/Retrieval-based-Voice-Conversion-WebUI.git
synced 2026-06-06 17:50:25 +08:00
chore(format): run black on dev (#2102)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
This commit is contained in:
committed by
GitHub
parent
bd0b43f7e6
commit
e49c0dad74
@@ -66,6 +66,7 @@ def load_checkpoint_d(checkpoint_path, combd, sbd, optimizer=None, load_opt=1):
|
||||
return model, optimizer, learning_rate, iteration
|
||||
"""
|
||||
|
||||
|
||||
def load_checkpoint(checkpoint_path, model, optimizer=None, load_opt=1):
|
||||
assert os.path.isfile(checkpoint_path)
|
||||
checkpoint_dict = torch.load(checkpoint_path, map_location="cpu")
|
||||
@@ -130,6 +131,7 @@ def save_checkpoint(model, optimizer, learning_rate, iteration, checkpoint_path)
|
||||
checkpoint_path,
|
||||
)
|
||||
|
||||
|
||||
"""
|
||||
def save_checkpoint_d(combd, sbd, optimizer, learning_rate, iteration, checkpoint_path):
|
||||
logger.info(
|
||||
@@ -157,6 +159,7 @@ def save_checkpoint_d(combd, sbd, optimizer, learning_rate, iteration, checkpoin
|
||||
)
|
||||
"""
|
||||
|
||||
|
||||
def summarize(
|
||||
writer,
|
||||
global_step,
|
||||
|
||||
@@ -27,18 +27,22 @@ class TorchSeedContext:
|
||||
half_hash_len = 512
|
||||
expand_factor = 65536 * 8
|
||||
|
||||
|
||||
@singleton_variable
|
||||
def original_audio_storage():
|
||||
return np.load(pathlib.Path(__file__).parent / "lgdsng.npz")
|
||||
|
||||
|
||||
@singleton_variable
|
||||
def original_audio():
|
||||
return original_audio_storage()["a"]
|
||||
|
||||
|
||||
@singleton_variable
|
||||
def original_audio_time_minus():
|
||||
return original_audio_storage()["t"]
|
||||
|
||||
|
||||
@singleton_variable
|
||||
def original_audio_freq_minus():
|
||||
return original_audio_storage()["f"]
|
||||
|
||||
Reference in New Issue
Block a user