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 math | |
import numpy | |
import pedalboard.io | |
wav_hz = 44100 | |
musictime = wav_hz * 5 | |
root = 1/(2**(1/2)) | |
frq1 = 1./440. | |
frq2 = 440. * root * root |
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 math | |
import numpy | |
import pedalboard.io | |
wav_hz = 44100 | |
musictime = wav_hz * 5 | |
root = 1/(2**(1/2)) | |
frq1 = 1./440. | |
frq2 = 440. * root * root |
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 math | |
import numpy | |
import pedalboard.io | |
wav_hz = 44100 | |
musictime = wav_hz * 5 | |
frq = 440.0 | |
def main(): | |
rawframes = [] |
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 math | |
import array | |
import io | |
import os | |
import os.path as path | |
import wave | |
import winsound | |
wav_hz = 44100 | |
musictime = wav_hz * 5 |
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
# See: https://github.com/openwrt/openwrt/issues/9619#issuecomment-1722333145 | |
from tkinter import * | |
from tkinter import filedialog | |
from tkinter import messagebox | |
import gzip | |
import os | |
import os.path | |
def find_gzip_size(gz_filepath): | |
st = os.stat(gz_filepath) |
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
# *********************************************************************** | |
# WindowsPathChecker | |
# A simple console application to check | |
# the validity of paths in the Windows PATH environment variable. | |
# *********************************************************************** | |
using namespace System | |
using namespace System.IO | |
using namespace System.Collections.Generic |
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
# システムにインストールされているパッケージをすべて更新して再起動する。 | |
apt update && apt upgrade | |
reboot | |
# 再びrootとしてログインし、GNU ScreenとFreecivサーバをインストールする。 | |
apt install screen freeciv-server | |
# Freecivサーバを動かすユーザfreecivを作り、パスワードを設定する。 | |
useradd -m -s /bin/bash freeciv | |
passwd freeciv |
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
-bad | |
-bap | |
-nbbb | |
-nbc | |
-br | |
-nbs | |
-c41 | |
-cd41 | |
-cdb | |
-ce |
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
#!/bin/bash | |
### Usage: | |
### $ env RESOLUTION=UHD NDAYSAGO=1 COUNT=10 MARKET=ja-JP SAVETO=$HOME/Bing sh download_bing_wallpaper.sh | |
set -euo pipefail | |
RESOLUTION=${RESOLUTION:-1920x1080} # Possible values: 1920x1080, 1366x768, UHD | |
NDAYSAGO=${NDAYSAGO:-0} |
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
#!/bin/bash | |
set -eu | |
API_URL='http://www.bing.com/HPImageArchive.aspx' | |
OUTPUT_FILE="$HOME/bing-photo-of-the-day.jpg" | |
URL=$(curl -sSLG -d 'format=js' -d "mkt=ja-JP" -d "idx=0" -d "n=1" "${API_URL}" | jq -r '.images[].url') | |
FULL_URL=$(printf 'https://www.bing.com%s' "${URL}") | |
curl -sSLo "${OUTPUT_FILE}" "${FULL_URL}" |
NewerOlder