Skip to content

Instantly share code, notes, and snippets.

View SolomidHero's full-sized avatar
🏠
Building cool things from home

SolomidHero

🏠
Building cool things from home
  • Moscow Institute of Physics and Technologies
  • Armenia, Yerevan
View GitHub Profile
@allquixotic
allquixotic / run_bepinex.sh
Created June 10, 2024 12:39
MacOS run_bepinex.sh for Valheim
#!/bin/sh
# BepInEx start script
#
# Run the script to start the game with BepInEx enabled
#
# There are two ways to use this script
#
# 1. Via CLI: Run ./run_bepinex.sh <path to game> [doorstop arguments] [game arguments]
# 2. Via config: edit the options below and run ./run.sh without any arguments
@hadware
hadware / bytes_to_wav.py
Last active March 27, 2025 09:51
Convert wav in bytes for to numpy ndarray, then back to bytes
from scipy.io.wavfile import read, write
import io
## This may look a bit intricate/useless, considering the fact that scipy's read() and write() function already return a
## numpy ndarray, but the BytesIO "hack" may be useful in case you get the wav not through a file, but trough some websocket or
## HTTP Post request. This should obviously work with any other sound format, as long as you have the proper decoding function
with open("input_wav.wav", "rb") as wavfile:
input_wav = wavfile.read()