This file contains hidden or 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
| from random import uniform | |
| from time import perf_counter | |
| import numpy as np | |
| import matplotlib.pyplot as plt | |
| from scipy.integrate import quad | |
| import getdist | |
| from getdist import plots | |
| c = 299_792.458 # km/s |
This file contains hidden or 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
| import numpy as np | |
| import matplotlib.pyplot as plt | |
| from matplotlib.animation import FuncAnimation | |
| from scipy.fftpack import fftn, ifftn | |
| import camb | |
| h=0.675 | |
| pars = camb.set_params( | |
| H0=100*h, ombh2=0.022, omch2=0.122, mnu=0.06, omk=0, tau=0.06, |
This file contains hidden or 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
| import sys | |
| import numpy as np | |
| from numpy.typing import NDArray | |
| import matplotlib.pyplot as plt | |
| # Number of samples to draw | |
| N = 200_000 | |
| # Distribution parameters |
This file contains hidden or 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
| class ansi: | |
| HEADER = '\033[95m' | |
| OKBLUE = '\033[94m' | |
| OKCYAN = '\033[96m' | |
| OKGREEN = '\033[92m' | |
| WARNING = '\033[93m' | |
| FAIL = '\033[91m' | |
| ENDC = '\033[0m' | |
| BOLD = '\033[1m' | |
| PINK = '\x1b[38;5;207m' |
This file contains hidden or 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
| from math import floor | |
| from pathlib import Path | |
| import sys | |
| import os | |
| import numpy as np | |
| import librosa | |
| import librosa.beat | |
| import soundfile as sf | |
| def synchronize(file_path_1, file_path_2, output_path="mashup.wav", second_iteration=False): |