Данная пошаговая инструкция поможет освоить основы на простом примере
Для справки
Сервер поднимался на Debian 8
c характеристиками:
CPU - 1 ядро x 500 МГц
{ | |
"name": "tf-js", | |
"version": "1.0.0", | |
"main": "script.js", | |
"license": "MIT", | |
"dependencies": { | |
"@tensorflow-models/mobilenet": "^0.2.2", | |
"@tensorflow/tfjs": "^0.12.3", | |
"@tensorflow/tfjs-node": "^0.1.9", | |
"jpeg-js": "^0.3.4" |
var cv = require('./node_modules/opencv/lib/opencv'); | |
var sleep = require('sleep'); | |
var camera = new cv.VideoCapture(0); //open camera | |
//set the video size to 512x288 | |
camera.setWidth(512); | |
camera.setHeight(288); | |
var window = new cv.NamedWindow('Camera'); | |
var firstFrame, frameDelta, gray, thresh; |
Helper setup to edit .yaml files with Vim:
List of general purpose commands for Kubernetes management:
Last updated March 13, 2024
This Gist explains how to sign commits using gpg in a step-by-step fashion. Previously, krypt.co was heavily mentioned, but I've only recently learned they were acquired by Akamai and no longer update their previous free products. Those mentions have been removed.
Additionally, 1Password now supports signing Git commits with SSH keys and makes it pretty easy-plus you can easily configure Git Tower to use it for both signing and ssh.
For using a GUI-based GIT tool such as Tower or Github Desktop, follow the steps here for signing your commits with GPG.
--- | |
- name: Install MacOS Packages | |
hosts: localhost | |
become: false | |
vars: | |
brew_cask_packages: | |
- atom | |
- docker | |
- dropbox | |
- firefox |
# The command finds the most recent tag that is reachable from a commit. | |
# If the tag points to the commit, then only the tag is shown. | |
# Otherwise, it suffixes the tag name with the number of additional commits on top of the tagged object | |
# and the abbreviated object name of the most recent commit. | |
git describe | |
# With --abbrev set to 0, the command can be used to find the closest tagname without any suffix: | |
git describe --abbrev=0 | |
# other examples |
Magic numbers are the first bits of a file which uniquely identify the type of file. This makes programming easier because complicated file structures need not be searched in order to identify the file type.
For example, a jpeg file starts with ffd8 ffe0 0010 4a46 4946 0001 0101 0047 ......JFIF.....G ffd8 shows that it's a JPEG file, and ffe0 identify a JFIF type structure. There is an ascii encoding of "JFIF" which comes after a length code, but that is not necessary in order to identify the file. The first 4 bytes do that uniquely.
This gives an ongoing list of file-type magic numbers.