chronos-api-backend / assets /encode_voice.py
RemanenetSpy
UI: Complete rebrand to Smriti by Kaal the Absolute
b49293b
Raw
History Blame Contribute Delete
297 Bytes
import base64
with open('assets/amber_voice.wav', 'rb') as f:
b64 = base64.b64encode(f.read()).decode()
print(f'Length: {len(b64)} chars ({len(b64)//1024} KB)')
with open('assets/amber_b64.py', 'w') as out:
out.write(f'AMBER_VOICE_B64 = "{b64}"\n')
print('Written to assets/amber_b64.py')