Skip to content

Instantly share code, notes, and snippets.

@imneov
imneov / README.md
Created February 21, 2025 14:04 — forked from rutcreate/README.md
Install Python 3.10.x on Ubuntu 20.04

Prerequisite

sudo apt update
sudo apt install software-properties-common -y

Add custom APT repository

POST /instances/start?model=LLaMA-2%20(7B) HTTP/1.1
Host: api.together.xyz
User-Agent: TogetherPythonOfficial/0.2.11
Accept-Encoding: gzip, deflate, br
Accept: */*
Connection: keep-alive
Authorization: Bearer 102488bd20430f40283c2b5247628785fa8a784feaea3ec0e952b7ad15e890a9
Content-Type: application/json
Content-Length: 0
@imneov
imneov / m1-max-numpy-setup.md
Created June 24, 2023 03:18 — forked from MarkDana/m1-max-numpy-setup.md
Install NumPy on M1 Max

How to install numpy on M1 Max, with the most accelerated performance (Apple's vecLib)? Here's the answer as of Dec 6 2021.


Steps

I. Install miniforge

So that your Python is run natively on arm64, not translated via Rosseta.

  1. Download Miniforge3-MacOSX-arm64.sh, then
  2. Run the script, then open another shell
$ bash Miniforge3-MacOSX-arm64.sh
@imneov
imneov / config.edn
Created October 28, 2022 03:56 — forked from QWxleA/config.edn
logseq configuration sept 2021
{;; Currently, we support either "Markdown" or "Org".
;; This can overwrite your global preference so that
;; maybe your personal preferred format is Org but you'd
;; need to use Markdown for some projects.
;; :preferred-format ""
;; Preferred workflow style.
;; Value is either ":now" for NOW/LATER style,
;; or ":todo" for TODO/DOING style.
:preferred-workflow :now
wget https://golang.google.cn/dl/go1.19.1.linux-amd64.tar.gz
rm -rf /usr/local/go && tar -C /usr/local -xzf go1.19.1.linux-amd64.tar.gz
echo '/etc/profile' >> /etc/profile
source /etc/profile
@imneov
imneov / 1.yaml
Created July 26, 2022 06:36
1.yaml
global:
resolve_timeout: 5m
http_config:
follow_redirects: true
smtp_hello: localhost
smtp_require_tls: true
pagerduty_url: https://events.pagerduty.com/v2/enqueue
opsgenie_api_url: https://api.opsgenie.com/
wechat_api_url: https://qyapi.weixin.qq.com/cgi-bin/
victorops_api_url: https://alert.victorops.com/integrations/generic/20131114/alert/
@imneov
imneov / lima-on-m1-mac-installation-guide.md
Created July 12, 2022 02:24 — forked from toricls/lima-on-m1-mac-installation-guide.md
Using Lima to run containers with containerd and nerdctl (without Docker Desktop) on M1 Macs

Lima (Linux virtual machines, on macOS) installation guide for M1 Mac.

Sep. 27th 2021 UPDATED

Now we can install patched version of QEMU via Homebrew (thank you everyone for the info!). Here is the updated instruction with it:

Used M1 Mac mini 2020 with macOS Big Sur Version 11.6.

1. Install QEMU & Lima

@imneov
imneov / QEMU-Silicon-Mac-Virtualization.md
Created July 12, 2022 01:40 — forked from nrjdalal/QEMU-Silicon-Mac-Virtualization.md
Create Virtual Machines using QEMU on Silicon based Apple Macs

Install QEMU on Silicon based Apple Macs (June 2021)

Option 1 - Automatically

zsh -c "$(curl -fsSL https://raw.githubusercontent.com/nrjdalal/silicon-virtualizer/master/install-qemu.sh)"

Option 2 - Manually

  • Install Xcode command line tools

xcode-select --install
{
"$id": "",
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "string"
}
@imneov
imneov / kubernetes-websocket.go
Created December 13, 2021 00:43 — forked from jezell/kubernetes-websocket.go
Connect to Kubernetes endpoint over websockets
package main
import (
"bytes"
"flag"
"golang.org/x/net/websocket"
"io"
"k8s.io/client-go/1.4/rest"
"k8s.io/client-go/1.4/tools/clientcmd"
"log"