Bias vs Variance in ML
Somehow even wiki https://en.wikipedia.org/wiki/Bias%E2%80%93variance_tradeoff seems not clearly explained what it is due to un-cleary math denotion. Here we refer to: model/algorithm’s bias and variance ( not the data itself ).…
optimization theory, lagrange, dual function, dual problem, KKT
Theory background min: f0(x) ==> p * s.t.: fi(x) <= 0 i = 1, … m hi(x) = 0 , j= 1 … m define lagrange function:…
mysql transcations
Generally how to write transaction Begin transaction by issuing the SQL command BEGIN WORK. Issue one or more SQL commands like SELECT, INSERT, UPDATE or DELETE. Check if there is no…
screen tmux cheat sheet
Screen screen -d -R your_session name //split only the monitor screen ctrl-a ( release the kb ), then press: | for vsplit —> need this step : ctrl-a, c…
c++ multi-set/multi-map, set/map and its unordered version
container name implementation/underlying struct notes/ sample unordered_set The value of an element is at the same time its key, that identifies it uniquely. hash table unordered_multiset much like unordered_set containers, but allowing different…
sip monitoring tools
Some good monitoring tools: homer: easy to install with docker for its server and install helifpy on a sip/client/host : nohup ./heplify -hs homer_server:9060 & grep sngrep, ngrep pcap tcpdump/wireshark…
vim cheat sheet
useful .vimrc set tabstop=2 set shiftwidth=2 set expandtab inoremap <S-Tab> <C-V><Tab> syntax on set t_Co=256 set colorcolumn=80 “crazy vim, do not allow copy/paste set mouse=v setlocal spell spelllang=en_us “for vert…
JIT compiler for interpreted language (python , js, php )
Compiled lang: src — compiler –> directly to machine code Interpreter( python/js) : src-> bytecode, run on VM ( a VM load bytecode, and do some switch for each type…
cross compile native libwebrtc ( on x86_64 host) for arm64
Direct compile webrtc on arm64 will fail: webrtc seems does not support direct support on arm, we will get errors: … Running hooks: 18% ( 4/22) sysroot_arm64 ________ running ‘vpython…
c++ json lib: nlohmann::json
nlohmann::json is a popluar json lib. code at: https://github.com/nlohmann/json document at: https://nlohmann.github.io/json/doxygen/index.html sample code: #include <iostream> 2 #include <nlohmann/json.hpp> 3 4 using json = nlohmann::json; 5 6 int main() 7 { 8 //…