Skip to content

Instantly share code, notes, and snippets.

import java.io.File;
import java.io.FileInputStream;
import java.io.IOException;
import java.io.InputStream;
import opennlp.tools.namefind.NameFinderME;
import opennlp.tools.namefind.TokenNameFinderModel;
import opennlp.tools.tokenize.Tokenizer;
import opennlp.tools.tokenize.TokenizerME;
import opennlp.tools.tokenize.TokenizerModel;
Although she has always lived in Myanmar , she speaks fluent English becaus her mother was <START:race> Shan <END> and her father was <START:race> Burmese <END> . Myanmar is a beautiful country. Japan provide money to Myanmar. United State also promised to support Myanmar in the future. <START:race> Kachin <END> live in New York. <START:race> Chin <END> is a race.<START:race>Kayin<END> is also a race.<START:race>Kayar<END> is also a race.<START:race>Mon<END> is also a race.<START:race>Yakine<END> is also a race.
IF(TL_HS_NGUNG_LUONGKY1 = 1, 0, TL_HS_K_DC_KY1 * NS_HSL * TL_HS_TL_TTDV)
public static void main(String[] arg){
ExpressionsEvaluator evalExpr = new ExpressionsBuilder("IF(TL_HS_NGUNG_LUONGKY1 == 1, 0, TL_HS_K_DC_KY1 * NS_HSL * TL_HS_TL_TTDV)").build();
Map<String, Object> variables = new HashMap<String, Object>();
variables.put("TL_HS_NGUNG_LUONGKY1", 10);
variables.put("TL_HS_K_DC_KY1", 10);
variables.put("NS_HSL", 1);
variables.put("TL_HS_TL_TTDV", 12);
System.out.println(evalExpr.eval(variables));
}
console.log "Simple expressions are evaluated: 5 x 6 = #{ 5 * 6 }"
var multiply = function(a, b) {
return a * b;
};
multiply = (a, b) ->
a * b
displayGreeting = ->
console.log 'Hello, world!'
displayGreeting()
import numpy as np
import cv2
img = cv2.imread('original12.jpg')
gray = cv2.cvtColor(img, cv2.COLOR_BGR2GRAY)
template = cv2.imread('tal.jpg',0)
# run template matching, get minimum val
res = cv2.matchTemplate(gray, template, cv2.TM_CCOEFF_NORMED)
/**
MyInfo v4 required JWKS and two certs(one for signing and one for encoding)
Following code will print out signing cert and encoding certs.
It will also print out the whole JWKS.
**/
const jose = require('node-jose');
const crypto = require('crypto');
async function generateKey(){
let key = crypto.generateKeyPairSync('ec', {