Skip to content

Instantly share code, notes, and snippets.

View budgetdevv's full-sized avatar
🤠
Professional Dumbass

TrumpMcDonaldz budgetdevv

🤠
Professional Dumbass
View GitHub Profile
[
"928350122843193385",
"1185047194261274665",
"956202276408688650",
"956104664821157918",
"1185047092478095443",
"1185046791826178099",
"1185047045413797898",
"928483283698851901",
"1185047444619284641",
@guschmue
guschmue / onnx-allnodes-are-outputs.py
Last active March 6, 2024 03:48
diff onnx models node by node
from __future__ import division
from __future__ import print_function
from __future__ import unicode_literals
import argparse
import logging
import traceback
import numpy as np
import onnx
@bmaupin
bmaupin / free-database-hosting.md
Last active May 21, 2024 14:39
Free database hosting
@codito
codito / pyembed.c
Last active March 16, 2024 20:29
A simple embedded python interpreter
// Demo a simple embedded python interpreter
// See this post for context: http://codito.in/notes-on-vim-python-interop
//
// Compile with: gcc $(python-config --cflags --ldflags) pyembed.c -o pyembed
// Tested on python 3.6 in arch linux
//
// See https://docs.python.org/3/c-api/init.html for details of APIs.
//
#include <Python.h>
@migasj
migasj / WindowsSystemErrorCodes.cs
Last active May 20, 2024 21:53
Windows System Error Codes enum (C#)
// Title: An exhaustive enum of all Windows System Error Codes
// Source: https://msdn.microsoft.com/en-us/library/windows/desktop/ms681381.aspx
// Description: Error codes are a means to provide information to outside systems on why a program terminated. This list
// need not be included in its entirety. It is meant to aid in conforming to the existing error code usage.
// See this link form more information on usage. https://msdn.microsoft.com/en-us/library/system.environment.exitcode.aspx
// Note: Internet error codes are excluded from this list. See here: https://msdn.microsoft.com/en-us/library/windows/desktop/aa385465.aspx
// Updated: 2016/10/31
namespace Core
{
@lars-tiede
lars-tiede / run_coroutine_in_another_thread.py
Created March 8, 2016 10:37
Safely run a coroutine in another thread's asyncio loop and return the result
import threading
import asyncio
async def run_coro_threadsafe(self, coro, other_loop, our_loop = None):
"""Schedules coro in other_loop, awaits until coro has run and returns
its result.
"""
loop = our_loop or asyncio.get_event_loop()
# schedule coro safely in other_loop, get a concurrent.future back
@myusuf3
myusuf3 / delete_git_submodule.md
Created November 3, 2014 17:36
How effectively delete a git submodule.

To remove a submodule you need to:

  • Delete the relevant section from the .gitmodules file.
  • Stage the .gitmodules changes git add .gitmodules
  • Delete the relevant section from .git/config.
  • Run git rm --cached path_to_submodule (no trailing slash).
  • Run rm -rf .git/modules/path_to_submodule (no trailing slash).
  • Commit git commit -m "Removed submodule "
  • Delete the now untracked submodule files rm -rf path_to_submodule