Skip to content

Instantly share code, notes, and snippets.

@ihoromi4
ihoromi4 / epson-v200-ubuntu-24-04.md
Last active September 27, 2026 15:19
epson-v200-ubuntu-24-04.md

How to Set Up Epson Perfection V200 Photo (GT-F670) Scanner on Ubuntu 24.04 LTS (Noble Numbat)

Note

This guide was prepared with the assistance of Antigravity + Gemini 3.8 Flash.

Legacy Epson Perfection scanners (such as Perfection V200 Photo / GT-F670, USB ID 04b8:012e) are marked as End-of-Support by Epson and use legacy iscan drivers.

On Ubuntu 24.04 LTS, attempting to install them causes several issues:

  1. iscan depends on the deprecated libsane package (superseded by libsane1).
  2. Epson's bundled install.sh script fails because it cannot resolve Provides: virtual dependencies (it tries to pull libgtk2.0-0, while Ubuntu 24.04 uses libgtk2.0-0t64).
@ihoromi4
ihoromi4 / images_to_zip.py
Last active February 5, 2020 12:09
convert numpy images to zip
import os
import zipfile
import numpy as np
import cv2
def images_to_zip(images: list, out_filename: str):
if os.path.exists(out_filename):
print('File', out_filename, 'already exists. Abort.')
return
@ihoromi4
ihoromi4 / seed_everything.py
Created February 5, 2020 11:49
pytorch - set seed everything
def seed_everything(seed: int):
import random, os
import numpy as np
import torch
random.seed(seed)
os.environ['PYTHONHASHSEED'] = str(seed)
np.random.seed(seed)
torch.manual_seed(seed)
torch.cuda.manual_seed(seed)
@ihoromi4
ihoromi4 / get_device_method.py
Last active February 5, 2020 11:50
pytorch - get nn.Module device method
from torch import nn
class NN(nn.Module):
def device(self):
return next(self.parameters()).device
@ihoromi4
ihoromi4 / get_n_params.py
Created February 5, 2020 11:45
pytorch - get number of a model parameters
import functools
import operator
from torch import nn
def get_n_params(model: nn.Module) -> int:
return sum((functools.reduce(operator.mul, p.size()) for p in model.parameters()))
import tensorflow as tf
from keras.backend.tensorflow_backend
config = tf.ConfigProto(device_count={'CPU': 1})
session = tf.Session(config=config)
tensorflow_backend.set_session(session)
@ihoromi4
ihoromi4 / main.go
Created May 18, 2018 10:51
golang multicast client-server
package main
import (
"encoding/hex"
"log"
"net"
"time"
)
const (