This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class FastImage | |
{ | |
Bitmap bm; | |
BitmapData bmpData; | |
public byte[] bytes; | |
public int Width, Height; | |
public FastImage(Bitmap bm) | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// require jsfeat | |
var options = { | |
blur_size: 5, | |
lap_thres: 30, | |
eigen_thres: 25 | |
} | |
var u_max = new Int32Array([15,15,15,15,14,14,14,13,13,12,11,10,9,8,6,3,0]); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
#include <string.h> | |
#include <iostream> | |
#include <ctime> | |
#include <math.h> | |
#include <fstream> | |
#include <opencv2/core.hpp> | |
#include <opencv2/features2d.hpp> | |
#include <opencv2/xfeatures2d.hpp> | |
#include <opencv2/highgui.hpp> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function table2js(t) | |
local type = type(t) | |
if type == "number" or type == "string" then | |
return t | |
end | |
if not (t[1] == nil) then -- check "t" is array | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var head = ['Різновидність лісових угідь', 'Різновид вологості ґрунту', 'Температура повітря ', 'Рівень пожежної безпеки']; | |
var data = [ | |
['Листові', 'Низька', '20', '1'], | |
['Листові', 'Низька', '30', '3'], | |
['Листові', 'Низька', '40', '5'], | |
['Листові', 'Середня', '20', '1'], | |
['Листові', 'Середня', '30', '2'], | |
['Листові', 'Середня', '40', '4'], | |
['Листові', 'Висока', '20', '1'], | |
['Листові', 'Висока', '30', '3'], |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var AssociationRules = function(transactions, MIN_SUPPORT, MAX_COMBINATION) { | |
var getOptions = function(data) { | |
var set = new Set(); | |
data.map(function(el) { | |
el.map(function(val) { | |
if (val != null) | |
set.add(val); | |
}); | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
delegate Color pixelMap(Color c); | |
delegate void pixelEach(Color c); | |
abstract class MyBitmap | |
{ | |
protected Bitmap bmp; | |
public abstract Color getPixel(int x, int y); | |
public abstract void setPixel(int x, int y, Color color); | |
public abstract void Save(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"parser": "babel-eslint", | |
"rules": { | |
"comma-dangle": [1, "never"], | |
"no-cond-assign": 1, | |
"no-console": 1, | |
"no-constant-condition": 1, | |
"sort-imports": "warn", | |
"no-duplicate-imports": "warn", | |
"no-control-regex": 1, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function _avg(x){ | |
return x.reduce((a,b) => a+b,0)/x.length; | |
} | |
function _avgK(x, k){ | |
var N = x.length; | |
var Nk = N-k; | |
return x.slice(0, Nk).reduce((a,b) => a+b,0)/Nk; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export class FrameQueue { | |
constructor(method) { | |
this.queue = []; | |
this.method = method; | |
this.ondone = null; | |
} | |
add() { | |
this.queue.push(this._f.apply(this, arguments)); |
OlderNewer