Skip to content

Instantly share code, notes, and snippets.

View yiyuezhuo's full-sized avatar
🦆

January Desk yiyuezhuo

🦆
View GitHub Profile
@yiyuezhuo
yiyuezhuo / json.lua
Created December 21, 2023 16:03
CMO JSON
function require_json()
-- https://github.com/rxi/json.lua/blob/master/json.lua
-- hack for CMO Lua
function rawget(t, k)
return t[k]
end
local json = { _version = "0.1.2" }
@yiyuezhuo
yiyuezhuo / gpu_stress_test.py
Last active December 10, 2023 02:01
gpu tensor test
import torch
from tqdm import tqdm
print(torch.cuda.is_available())
t_cpu = torch.zeros(10000, 10000)
t_cpu2 = torch.zeros(10000, 10000)
tt_cpu = t_cpu * t_cpu2
t_gpu = t_cpu.cuda()
@yiyuezhuo
yiyuezhuo / waterloo_oob_IL_extraction.ipynb
Last active October 31, 2023 03:58
Extract Waterloo OOB
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@yiyuezhuo
yiyuezhuo / detection.lua
Last active February 20, 2023 09:38
CMO_Detection_Test_automation
Executor = {
attacker_list=nil,
defender=nil,
}
Executor.__index = Executor
function Executor:new()
local o = {}
setmetatable(o, self)
return o
end
@yiyuezhuo
yiyuezhuo / SNDW_IEEE2006OfficeOnline.xsl
Created February 19, 2023 03:15
SNDW_word_reference_style
<?xml version="1.0" encoding="utf-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:msxsl="urn:schemas-microsoft-com:xslt"
xmlns:b="http://schemas.openxmlformats.org/officeDocument/2006/bibliography" xmlns:t="http://www.microsoft.com/temp">
<xsl:output method="html" encoding="us-ascii"/>
<xsl:template match="/">
<xsl:call-template name="Start"/>
</xsl:template>
@yiyuezhuo
yiyuezhuo / modeling3-pruned.ipynb
Created January 5, 2023 18:57
basic_industrial_revolution_transition_from_workshop_to_factory_modeling
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@yiyuezhuo
yiyuezhuo / draw_simple_hex.ipynb
Created December 22, 2022 23:57
draw simple hex
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@yiyuezhuo
yiyuezhuo / test_proxy.py
Created June 17, 2022 13:27
test proxy
import requests
proxies = {"http": "http://127.0.0.1:8889", "https": "http://127.0.0.1:8889"}
url = "https://www.google.com"
%time requests.get(url, proxies=proxies)
from multiprocessing.pool import ThreadPool
%%time
@yiyuezhuo
yiyuezhuo / notebook2.ipynb
Last active May 29, 2022 07:59
Simulation trajectory and Kalman Filter for a stochastic dodge game
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@yiyuezhuo
yiyuezhuo / projection_matrix_julia.ipynb
Last active April 18, 2022 14:25
projection_matrix_julia.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.