Skip to content

Instantly share code, notes, and snippets.

View dotcs's full-sized avatar

FG dotcs

View GitHub Profile
@dotcs
dotcs / comics.json
Last active March 25, 2023 06:07
Alle Kaenguru Comics von zeit.de (https://www.zeit.de/serie/die-kaenguru-comics)
[
{
"id": 478,
"title": "Emotional berühren",
"date": "2022-09-13T11:58:57+02:00",
"img": {
"src": "https://img.zeit.de/administratives/kaenguru-comics/2022-09/13/original__ffffff",
"width": 4000,
"height": 1453,
"ratio": 2.752925
@dotcs
dotcs / ipv4-to-ipv6-bridge.sh
Created March 24, 2019 15:21
Script that creates an IPv4-to-IPv6 bridge
#!/usr/bin/env bash
# This script determines the IPv6 address of a given domain. The so found
# address is then used to create an IPv4-to-IPv6 tunnel from this device to the
# IPv6 address.
# [6tunnel](https://packages.debian.org/de/sid/6tunnel) is used to create the
# proxy.
#
# Usage: ./ipv6-mapper.sh <DOMAIN> <HOST_PORT=443> <TARGET_PORT=443>
import tensorflow as tf
from tensorflow.python.saved_model import builder as saved_model_builder
from tensorflow.python.saved_model import signature_constants
from tensorflow.python.saved_model import signature_def_utils
from tensorflow.python.saved_model import tag_constants
from tensorflow.python.saved_model.utils import build_tensor_info
model_path = './frozen/inception_v3_2016_08_28_frozen.pb'
target_dir = './models/inception/3'
mkdir -p tensorflow-serving/{frozen,models}
cd tensorflow-serving
curl -L "https://storage.googleapis.com/download.tensorflow.org/models/inception_v3_2016_08_28_frozen.pb.tar.gz" |
tar -C frozen -xz
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@dotcs
dotcs / Main.elm
Created September 16, 2016 19:38
Elm example with two dices
import Html exposing (..)
import Html.App as App
import Html.Events exposing (onClick)
import Random
main =
App.program
{ init = init
, view = view
, update = update
@dotcs
dotcs / AsyncDemoComponent.jsx
Last active September 9, 2015 17:01
Demo that shows problem in react-select
'use strict';
import React, { Component, PropTypes } from 'react';
import Select from 'react-select';
class RecipientSelect extends Component {
constructor() {
super();
this.asyncOptionsHandler = this.asyncOptionsHandler.bind(this);