This file contains hidden or 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
#!/bin/sh | |
# Dependency: | |
# spirv-llvm-translator | |
# opencl-icd-loader opencl-headers | |
# | |
# level-zero-loader level-zero-headers | |
# or | |
. /opt/intel/oneapi/setvars.sh |
This file contains hidden or 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
#!/usr/bin/env python3 | |
""" | |
Script to use my old laptop as Babyphone. | |
Turn on monitor (tty) back light in the evening. | |
Require root to change the tty color scheme to white and tune the screen brightness. | |
pip install opencv-python flask flask-socketio simple-websocket sounddevice | |
""" | |
import datetime |
This file contains hidden or 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
" let g:llm_grammar_apiurl = 'https://api.groq.com/openai/v1/chat/completions' | |
" let g:llm_grammar_model = 'llama3-70b-8192' | |
let g:llm_grammar_apikey = 'YOUR KEY' | |
vnoremap <silent> <leader>ll :<C-u>call LLMGrammarVisual()<CR> | |
function! LLMGrammarVisual() | |
let l:start = line("'<") | |
let l:end = line("'>") | |
let l:lines = getline(l:start, l:end) | |
let l:text = join(l:lines, "\n") |
This file contains hidden or 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
#!/usr/bin/perl | |
# | |
# Script to calibrate the measured result | |
# | |
# Author: wuchuanren@gmail.com | |
# Date: 01.Jun. 2013 | |
# | |
use strict; |
This file contains hidden or 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
"" feko | |
autocmd BufNewFile,BufRead *.pre set filetype=feko | |
autocmd filetype feko call Feko() | |
function! Feko() | |
"" Syntax Highlight | |
set syntax=feko |
This file contains hidden or 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
{- | |
x^(n-1) % n == 1 | |
k == n-1 == d*(2^m) | |
und | |
a^d % n == (1 || n-1) | |
oder irgendeine | |
a^(d * (2^i)) % n == n-1 | |
davon, i = 1, 2, 3 ... m | |
-} |
This file contains hidden or 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
int MillerRabin(uint32_t a, int n) | |
{ | |
/* x^(n-1) % n == 1 */ | |
/* k == n-1 == d*(2^m) */ | |
/* davon : | |
* a^d % n == 1 | |
* oder | |
* a^(d * (2^i)) % n == n-1 | |
* davon, i = 1, 2, 3 ... |