Skip to content

Instantly share code, notes, and snippets.

dimagalat /
Last active November 16, 2023 18:07
A cleaning function suitable for deep learning applications
import re
import string
import unicodedata
from typing import Optional
class TextNorm:
def __init__(self):
dimagalat /
Created March 5, 2022 16:54 — forked from alyleite/
Failed to connect to bus: Host is down - WSL 2

» sudo systemctl daemon-reload

System has not been booted with systemd as init system (PID 1). Can't operate. Failed to connect to bus: Host is down

just try:

sudo apt-get update && sudo apt-get install -yqq daemonize dbus-user-session fontconfig

sudo daemonize /usr/bin/unshare --fork --pid --mount-proc /lib/systemd/systemd

#!/usr/bin/env sh
# This script downloads the Google News word2vec negative 300 model.
# Script code was taken from
DIR="$( cd "$(dirname "$0")" ; pwd -P )"
cd $DIR
dimagalat /
Created March 24, 2016 00:41 — forked from staltz/
The introduction to Reactive Programming you've been missing