Skip to content

Instantly share code, notes, and snippets.

View x213212's full-sized avatar
🏖️

x213212 x213212

🏖️
View GitHub Profile
@x213212
x213212 / llvm create cfg.sh
Created December 14, 2022 03:21 — forked from bdqnghi/llvm create cfg.sh
create CFG with llvm
#!/bin/bash
# create .bc file
clang -emit-llvm -c testcfg.c
# create .dot file
opt -dot-cfg testcfg.bc
# cteate png,pdf
dot -Tpng -o main.png cfg.main.dot
00000000000012c8 <matrix_test>:
matrix_test():
/home/users3/rex603/automation/CoreMark-V5/demo/core_matrix.c:131
After the last step, matrix A is back to original contents.
*/
ee_s16
matrix_test(ee_u32 N, MATRES *C, MATDAT *A, MATDAT *B, MATDAT val)
{
@x213212
x213212 / life.c
Last active September 30, 2022 11:00
#include "os.h"
#include <stdio.h>
#include <stdlib.h>
//#include<string.h>
#define WIDTH 250
#define HEIGHT 200
#define ACTIVE 1
#define INACTIVE 0
#define ACTIVE_SYMBOL '*'
@x213212
x213212 / test4.py
Created January 21, 2021 06:10
typechecker
from hub.schema import Primitive, Audio, ClassLabel
from hub import transform, schema
import warnings
import librosa
import numpy as np
import matplotlib.pyplot as plt
from tqdm import tqdm
from glob import glob
from time import time
# -*- coding=utf-8 -*-
import time
from kucoin.client import Client
import json
import datetime
import os
import time
import sys
import math
import string
@x213212
x213212 / ffmpeg.js
Created October 16, 2019 09:04
outputfilebuffer
var TTY = {
ttys: [],
init: function() {},
shutdown: function() {},
showbuff : function () {},
register: function(dev, ops) {
TTY.ttys[dev] = {
input: [],
output: [],
ops: ops
@x213212
x213212 / ffmpeg.js
Created October 16, 2019 09:04
outputfilebuffer
var TTY = {
ttys: [],
init: function() {},
shutdown: function() {},
showbuff : function () {},
register: function(dev, ops) {
TTY.ttys[dev] = {
input: [],
output: [],
ops: ops
sma_5 = talib.SMA(np.array(close), 5)
sma_10 = talib.SMA(np.array(close), 10)
sma_20 = talib.SMA(np.array(close), 20)
sma_60 = talib.SMA(np.array(close), 60)
macd = get_MACD(np.array(close))
#
data_list4 = []
for x in range (len (randomforest_list)-1 , 33 ,-1 ):
@x213212
x213212 / flask_api.py
Last active May 6, 2020 14:58
stock.vue
# -*- coding: utf-8 -*-
"""
Created on Wed Dec 20 17:46:15 2017
@author: user
"""
import sys
from flask import Flask
from flask_restful import reqparse, abort, Api, Resource
import logging
@x213212
x213212 / lua.conf
Created July 12, 2019 06:19
websocket server
server {
listen 6699;
location /lua {
default_type text/html;
lua_code_cache off;
content_by_lua_file /home/x213212/openresty-test/conf/lua/test.lua;
}
location = /sredis {
content_by_lua_file /home/x213212/openresty-test/conf/lua/ws_redis.lua;
}