Skip to content

Instantly share code, notes, and snippets.

@trigrass2
trigrass2 / seafile-on-lxd.md
Created April 11, 2020 11:47
Seafile instance on LXD

Seafile + sqlite instance on LXD lab

This lab assumes that we have a running LXD setup based on this gist : UNprivileged lxd containers on top of Open vSwitch

Let's start with a container named seafile.

$ lxc ls
+---------+---------+-------------------+-----------------------------------+------------+-----------+
| NAME | STATE | IPV4 | IPV6 | TYPE | SNAPSHOTS |
#!/usr/bin/env python
import time
import rospy
from hrpsys_ros_bridge.srv import *
import math
from uarm.msg import Joints
from std_msgs.msg import Bool
@trigrass2
trigrass2 / cnn ocr
Created February 22, 2017 11:48 — forked from xlvector/cnn ocr
# pylint: disable=C0111,too-many-arguments,too-many-instance-attributes,too-many-locals,redefined-outer-name,fixme
# pylint: disable=superfluous-parens, no-member, invalid-name
import sys
sys.path.insert(0, "../../python")
import mxnet as mx
import numpy as np
import cv2, random
from io import BytesIO
from captcha.image import ImageCaptcha
@trigrass2
trigrass2 / googlenet.py
Created January 7, 2017 13:17 — forked from joelouismarino/googlenet.py
GoogLeNet in Keras
from scipy.misc import imread, imresize
from keras.layers import Input, Dense, Convolution2D, MaxPooling2D, AveragePooling2D, ZeroPadding2D, Dropout, Flatten, merge, Reshape, Activation
from keras.models import Model
from keras.regularizers import l2
from keras.optimizers import SGD
from googlenet_custom_layers import PoolHelper,LRN
def create_googlenet(weights_path=None):
@trigrass2
trigrass2 / readme.md
Created January 4, 2017 12:50 — forked from ricgu8086/readme.md
VGG-16 pre-trained model for Keras

##VGG16 model for Keras

This is the Keras model of the 16-layer network used by the VGG team in the ILSVRC-2014 competition.

It has been obtained by directly converting the Caffe model provived by the authors.

Details about the network architecture can be found in the following arXiv paper:

Very Deep Convolutional Networks for Large-Scale Image Recognition

K. Simonyan, A. Zisserman

@trigrass2
trigrass2 / pg-pong.py
Created December 30, 2016 08:54 — forked from karpathy/pg-pong.py
Training a Neural Network ATARI Pong agent with Policy Gradients from raw pixels
""" Trains an agent with (stochastic) Policy Gradients on Pong. Uses OpenAI Gym. """
import numpy as np
import cPickle as pickle
import gym
# hyperparameters
H = 200 # number of hidden layer neurons
batch_size = 10 # every how many episodes to do a param update?
learning_rate = 1e-4
gamma = 0.99 # discount factor for reward
@trigrass2
trigrass2 / .config
Created June 15, 2016 07:50 — forked from sajal/.config
gccgo on WT1520
#
# Automatically generated file; DO NOT EDIT.
# OpenWrt Configuration
#
CONFIG_MODULES=y
CONFIG_HAVE_DOT_CONFIG=y
# CONFIG_TARGET_ppc40x is not set
# CONFIG_TARGET_realview is not set
# CONFIG_TARGET_arm64 is not set
# CONFIG_TARGET_sunxi is not set