Skip to content

Instantly share code, notes, and snippets.

View Luxter77's full-sized avatar
πŸ’­
In the process of imploding

Lucas Daniel Velazquez M. Luxter77

πŸ’­
In the process of imploding
View GitHub Profile
@naviocean
naviocean / nvidia_driver.md
Last active February 12, 2023 13:16
Install Nvidia Driver, Cuda, Cudnn on ubuntu

1. Install NVIDIA Driver Version 390 via apt-get

sudo add-apt-repository ppa:graphics-drivers/ppa
sudo apt-get update
sudo apt-get install nvidia-390 nvidia-modprobe

To verify installation, restart your machine with reboot and type nvidia-smi.

2. Install Cuda 9.0

@nikhilkumarsingh
nikhilkumarsingh / real_time.ipynb
Created August 19, 2018 20:04
Plotting real time data using Python
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@vxgmichel
vxgmichel / long_sleep.py
Last active October 19, 2020 15:38
Asyncio long sleep (over 1 day)
import asyncio
async def long_sleep(arg):
hours = 60*60
async def bg():
while True:
await asyncio.sleep(12 * hours)
@mutin-sa
mutin-sa / Top_Public_Recursive_Name_Servers.md
Last active July 13, 2025 04:34
List of Top Public Recursive Name Servers

DNS:

IPv4 Addr IPv6 Addr ASn Political Region Loc Svc Org
8.8.8.8 2001:4860:4860::8888 AS15169 US Worldwide (Anycast) Google Public DNS Google
8.8.4.4 2001:4860:4860::8844 AS15169 US Worldwide (Anycast) Google Public DNS Google
1.1.1.1 2606:4700:4700::1111 AS13335 US Worldwide (Anycast) Cloudflare-DNS Cloudflare/APNIC
1.0.0.1 2606:4700:4700::1001 AS13335 US Worldwide (Anycast) Cloudflare-DNS Cloudflare/APNIC
95.85.95.85 2a03:90c0:999d::1 AS199524 EU *W
@timvisee
timvisee / falsehoods-programming-time-list.md
Last active July 21, 2025 13:21
Falsehoods programmers believe about time, in a single list

Falsehoods programmers believe about time

This is a compiled list of falsehoods programmers tend to believe about working with time.

Don't re-invent a date time library yourself. If you think you understand everything about time, you're probably doing it wrong.

Falsehoods

  • There are always 24 hours in a day.
  • February is always 28 days long.
  • Any 24-hour period will always begin and end in the same day (or week, or month).
@aras-p
aras-p / main.cpp
Last active December 3, 2017 13:06
Slow to compile inline tables under MSVC
// See http://aras-p.info/blog/2017/10/24/Slow-to-Compile-Table-Initializers/
//
// Some combination of "enums-like-ints" utilities (global operators) and
// large constant data tables placed inside functions (instead of global variables)
// is causing VS2015+ to be fairly slow at compiling with /O2
//
// Here's a simplified excerpt taken from a larger codebase (Unity game engine),
// and cut down a bit to have a small-ish repro. The most slow part was the
// GetDesc function, with a large FormatDesc table initialization inside of it,
// coupled with FormatPropertyFlags using ENUM_FLAGS macros to define "type-safe"
@kmhofmann
kmhofmann / building_tensorflow.md
Last active December 16, 2024 20:45
Building TensorFlow from source

Building TensorFlow from source (TF 2.3.0, Ubuntu 20.04)

Why build from source?

The official instructions on installing TensorFlow are here: https://www.tensorflow.org/install. If you want to install TensorFlow just using pip, you are running a supported Ubuntu LTS distribution, and you're happy to install the respective tested CUDA versions (which often are outdated), by all means go ahead. A good alternative may be to run a Docker image.

I am usually unhappy with installing what in effect are pre-built binaries. These binaries are often not compatible with the Ubuntu version I am running, the CUDA version that I have installed, and so on. Furthermore, they may be slower than binaries optimized for the target architecture, since certain instructions are not being used (e.g. AVX2, FMA).

So installing TensorFlow from source becomes a necessity. The official instructions on building TensorFlow from source are here: ht

@jagrosh
jagrosh / Github Webhook Tutorial.md
Last active July 17, 2025 23:46
Simple Github -> Discord webhook

Step 1 - Make a Discord Webhook

  1. Find the Discord channel in which you would like to send commits and other updates

  2. In the settings for that channel, find the Webhooks option and create a new webhook. Note: Do NOT give this URL out to the public. Anyone or service can post messages to this channel, without even needing to be in the server. Keep it safe! WebhookDiscord

Step 2 - Set up the webhook on Github

  1. Navigate to your repository on Github, and open the Settings Settings
@ab
ab / πŸ’©.rb
Last active November 16, 2020 22:25
#!/usr/bin/env ruby
alias πŸ“„ puts
class AπŸ–₯
@@🐴 = {
πŸ˜‚: 'Hello, world!',
πŸ™ƒ: 'HALP',
πŸ–₯: 'computer.',
}
@mpetroff
mpetroff / jail.local
Last active March 28, 2025 03:19
JupyterHub PAM Authentication Fail2ban Configuration
# /etc/fail2ban/jail.local
[jupyterhub]
enabled = true
port = 443
filter = jupyterhub
backend = systemd
maxretry = 6