Skip to content

Instantly share code, notes, and snippets.

View MiXaiLL76's full-sized avatar
🏠
Working from home

Михаил MiXaiLL76

🏠
Working from home
View GitHub Profile
import matplotlib.pyplot as plt
import torch
from torch.optim import SGD
from torch.optim.lr_scheduler import ExponentialLR, CosineAnnealingWarmRestarts, CosineAnnealingLR
model = [torch.nn.Parameter(torch.randn(2, 2, requires_grad=True))]
GPU_COUNT = 1
@MiXaiLL76
MiXaiLL76 / delete.sh
Created September 2, 2021 14:16
Safe replacement for rm -rf for gnome ubuntu
#!/bin/bash
trash_dir=/home/rdl/.local/share/Trash
trash_files="${trash_dir}/files"
trash_info="${trash_dir}/info"
echo "Save remove files"
if [ $1 ]; then
@MiXaiLL76
MiXaiLL76 / jupyter.service
Last active June 12, 2020 08:10 — forked from whophil/jupyter.service
A systemd script for running a Jupyter notebook server.
# Setting up a Jupyter Lab remote server raspberry
[Unit]
Description=Jupyter Lab
[Service]
Type=simple
PIDFile=/run/jupyter.pid
ExecStart=/home/pi/.local/bin/jupyter-lab --config=/home/pi/.jupyter/jupyter_notebook_config.py
User=pi