π
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
alias ls="eza --color=always --long --no-filesize --icons=always --no-time --no-user --no-permissions" |
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
[env] | |
TERM = "xterm-256color" | |
# this connects to another script that controsl the daytime switch of themes | |
# https://github.com/alacritty/alacritty/issues/5999#issuecomment-2053664635 | |
ALACRITTY_THEME_SYSTEM_SWITCH = "true" | |
ALACRITTY_THEME_SYSTEM_DAY = "dayfox" | |
ALACRITTY_THEME_SYSTEM_NIGHT = "nightfox" | |
[window] | |
padding.x = 10 |
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
import datetime | |
import os | |
import shutil | |
import pandas as pd | |
from loguru import logger | |
DATE_FORMAT = "%Y-%m-%d" | |
DEFAULT_FOLDER = "" | |
DAILY_TEMPLATE_FILE = "" |
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
import time | |
import wave | |
from dataclasses import asdict, dataclass | |
import pyaudio | |
import torch | |
from transformers import AutoModelForSpeechSeq2Seq, AutoProcessor, pipeline | |
@dataclass |
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
{ | |
"notebook.formatOnSave.enabled": true, | |
"notebook.codeActionsOnSave": { | |
"notebook.source.fixAll": "explicit", | |
"notebook.source.organizeImports": "explicit" | |
}, | |
"[python]": { | |
"editor.formatOnSave": true, | |
"editor.codeActionsOnSave": { | |
"source.fixAll": "explicit", |
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
if [[ -z $ZSH_THEME_CLOUD_PREFIX ]]; then | |
ZSH_THEME_CLOUD_PREFIX='π₯' #β‘' | |
fi | |
PROMPT='%{$fg_bold[cyan]%}$ZSH_THEME_CLOUD_PREFIX%{$fg_bold[green]%} %{$fg[green]%}%c %{$fg_bold[cyan]%}$(git_prompt_info)%{$fg_bold[blue]%} % %{$reset_color%}' | |
ZSH_THEME_GIT_PROMPT_PREFIX="%{$fg[green]%}[%{$fg[cyan]%}" | |
ZSH_THEME_GIT_PROMPT_SUFFIX="%{$reset_color%}" | |
ZSH_THEME_GIT_PROMPT_DIRTY="%{$fg[green]%}] %{$fg[yellow]%}'%{$reset_color%}" | |
ZSH_THEME_GIT_PROMPT_CLEAN="%{$fg[green]%}]" |
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
FROM nvidia/cuda:12.1.1-devel-ubuntu20.04 | |
ARG DEBIAN_FRONTEND=noninteractive | |
# install git, python3.10 and pip | |
RUN apt-get update && apt-get install -y \ | |
git \ | |
curl \ | |
software-properties-common \ | |
&& add-apt-repository ppa:deadsnakes/ppa \ | |
&& apt install -y python3.10 \ | |
&& rm -rf /var/lib/apt/lists/* \ |
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
plugins=( | |
git | |
zsh-autosuggestions | |
alias-finder | |
dotenv | |
poetry | |
python | |
macos | |
gitignore | |
web-search |
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
# Three main sources for this script: | |
# https://github.com/rocker-org/rocker-versioned2/issues/144 | |
# https://jsta.github.io/r-docker-tutorial/02-Launching-Docker.html | |
# https://stackoverflow.com/questions/65456814/docker-apple-silicon-m1-preview-mysql-no-matching-manifest-for-linux-arm64-v8 | |
# After running the script, access the RStudio on the address http://localhost:8787/ | |
docker run --rm \ | |
--platform linux/x86_64 \ | |
-p 8787:8787 \ |
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
def multinomial_goodness_of_fit( | |
f_obs, | |
p_exp=None, | |
b=1000, | |
delta=0 | |
) -> list: | |
""" | |
Calculate the multinomial goodness of fit through Log Likelihood Ratio test statistic with the | |
null distribution calculated via Monte Carlo simulation. |
NewerOlder