Skip to content

Instantly share code, notes, and snippets.

@mkrupczak3
mkrupczak3 / requirements.txt
Created July 25, 2023 15:53 — forked from claysauruswrecks/requirements.txt
Example using LlamaHub loaders to index Github repos into LlamaIndex and query GPTSimpleVectorIndex with GPT-4
# main
llama-index
langchain
@mkrupczak3
mkrupczak3 / gist:f283e1cc48cf5cc876cb7fe36f57fc94
Created August 11, 2022 15:54 — forked from ppearson/gist:52774
Python NMEA to GPX converter script
# NMEA to GPX converter
# Peter Pearson
# version 0.11
import csv
import sys
import time
from time import strftime
def convert_dms_to_dec(value, dir):
@mkrupczak3
mkrupczak3 / protrails_to_gpx.py
Created August 11, 2022 15:46 — forked from kingds/protrails_to_gpx.py
Python script for converting sets of GPS coordinates from protrails.com into a GPX file which can be loaded onto a GPS device.
#!/usr/bin/env python
# -*- coding: utf-8 -*-
# This is a script for converting coordinates from a protrails.com trail description into a
# gpx file that can be loaded onto a GPS device.
# In order to use it, copy and paste the coordinates from the protrails map page (not the
# main page for the hike, but the page with the link "Interactive GPS Topo Map") into an input
# file. Run the script with # python protrails_to_gpx.py <input file> <output file> <route name>
from lxml import etree as tree
@mkrupczak3
mkrupczak3 / Homoglyphs.md
Created August 8, 2022 19:25 — forked from StevenACoffman/Homoglyphs.md
Unicode Look-alikes

Unicode Character Look-Alikes

Original Letter Look-Alike(s)
a а ạ ą ä à á ą
c с ƈ ċ
d ԁ ɗ
e е ẹ ė é è
g ġ
h һ
@mkrupczak3
mkrupczak3 / nginx_deployment.yaml
Created November 17, 2021 23:11 — forked from petitviolet/nginx_deployment.yaml
sample Nginx configuration on Kubernetes using ConfigMap to configure nginx.
apiVersion: v1
kind: ConfigMap
metadata:
name: nginx-conf
data:
nginx.conf: |
user nginx;
worker_processes 3;
error_log /var/log/nginx/error.log;
events {
@mkrupczak3
mkrupczak3 / miui-instagram-video-encoding-fix.md
Created October 11, 2021 20:03
Splitting, cropping and converting video for Instagram

Short description

Just a short reminder to self, when i'll be struggling with uploading video to Instagram. For some reason my MIUI v5 port has troubles with recording proper video to be successfully uploaded to Instagram.

First of all: encoding should be mpeg4, not h264!, regardless of file extension (but should probably be mp4).

All the options passed to ffmpeg are order dependant: first options executed first, last will override previous. Thus, input file is defined early, output file is defined at the very end.

All filters can be setup per stream (a for audio and v for video) and should be defined as -filter (for both),

Core Coding Standard

Coding practices are a source of a lot of arguments among programmers. Coding standards, to some degree, help us to put certain questions to bed and resolve stylistic debates. No coding standard makes everyone happy. (And even their existence is sure to make some unhappy.) What follows are the standards we put together on the Core team, which have become the general coding standard for all programming teams on new code development. We’ve tried to balance the need for creating a common, recognizable and readable code base with not unduly burdening the programmer with minor code formatting concerns.

Table Of Contents

@mkrupczak3
mkrupczak3 / screen-tearing.md
Created October 3, 2020 22:39 — forked from Brottweiler/screen-tearing.md
Screen tearing in Linux

Screen Tearing in Linux

The purpose of this gist is to document my experiences with screen tearing in Linux.

Information

  • Archlinux
  • i5-4460 (4) @ 3.4GHz
  • GeForce GTX 750 Ti
@mkrupczak3
mkrupczak3 / webex-ubuntu.md
Created April 9, 2020 22:12 — forked from mshkrebtan/webex-ubuntu.md
Run Cisco Webex on 64-bit Ubuntu 16.04

Run Cisco Webex on 64-bit Ubuntu 16.04

With Audio and Screen Sharing Enabled

Enable support for 32-bit executables

Add the i386 architecture to the list of dpkg architectures :

sudo dpkg --add-architecture i386
@mkrupczak3
mkrupczak3 / gist:9f5412ceb179f9fc08bfae8ccbb4aec2
Created March 7, 2020 22:44
COVID-19 OoC (Outside of China) Growth
// WHO Reports: https://www.who.int/emergencies/diseases/novel-coronavirus-2019/situation-reports
// Inspired by: https://twitter.com/paulg/status/1235247452145451013
// Note: The growth rate does not seem sustainable.
// The projected OoC infections assumes a constant doubling of roughly every 4 days.
Date Projected-OoC-Infections WHO-Reported-OoC-Infections
2020-02-29 5,629 6,009
2020-03-01 6,755 7,169
2020-03-02 8,106 8,774
2020-03-03 9,727 10,565
2020-03-04 11,673 12,669