This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/python3 python | |
"""Benchmark for Python MIDI parsing libraries. | |
""" | |
import random | |
from pathlib import Path | |
from time import time | |
from typing import Sequence |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Here the job is relaunched if it was not 100% completed, that is until a specific file exists | |
# The --wait argument allows to hang the execution until the job execution ends, before resubmitting it if needed | |
# Set vars | |
NAME=$1 | |
JOB_FILE="train_$NAME.sh" | |
TRAIN_FILE="runs/gen_MMD/TSD_$NAME/train_results.json" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
Small script estimating the training time of models, depending on number of nodes / GPUs / batch size... | |
""" | |
from pprint import pformat | |
from math import ceil | |
def sec_to_hours(nb_sec: float, no_seconds: bool = False) -> str: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/python3 python | |
"""Test chord detection methods | |
""" | |
from dataclasses import dataclass | |
from typing import List, Tuple, Dict, cast | |
from copy import copy |