Skip to content

Instantly share code, notes, and snippets.

@mcvarer
mcvarer / cuda-11.2_installation_on_Ubuntu-18.04
Last active March 12, 2024 02:29
CUDA 11.2 Installation on Ubuntu 18.04
#!/bin/bash
## This gist contains instructions about cuda v11.2 and cudnn 8.1 installation in Ubuntu 18.04 for PyTorch
#############################################################################################
##### forked by : https://gist.github.com/Mahedi-61/2a2f1579d4271717d421065168ce6a73 ########
#############################################################################################
### steps ####
# verify the system has a cuda-capable gpu
#! /usr/bin/python
from scapy.all import *
import sys, ifaddr, os
bad_sites = [
'reddit.com',
'youtube.com',
'news.ycombinator.com',
'wsj.com',
@espdev
espdev / cudnn.txt
Created July 8, 2016 09:42
Install cuDNN 4.0
$ tar -zxvf cudnn-7.0-linux-x64-v4.0-prod.solitairetheme8
$ cd cuda
$ sudo cp include/cudnn.h /usr/local/include
$ sudo cp lib64/libcudnn.* /usr/local/lib
@madskristensen
madskristensen / ImportMefComponent.cs
Last active May 3, 2020 07:02
Import MEF components from non-MEF exported classes
using System.ComponentModel.Composition;
using Microsoft.VisualStudio.Shell;
using Microsoft.VisualStudio.Shell.TableManager;
public class ExtensionPackage : Package
{
[Import]
private ITableManagerProvider _tableManagerProvider;
protected override void Initialize()
@aantix
aantix / gist:1999816
Created March 8, 2012 09:08
Remote Pair Programming sucks. Here's how to solve it.

REAL WORLD SCENARIO (blinking lights)

Mr. Tom Dev wants to remote pair program with Mr. Todd Programmer. Tom is in New York, Todd is in San Francisco. They’re working on yet another blog written in Ruby. Tom fires up Rubymine, Todd fires up TextMate.

Todd’s editor quickly alerts him that he is connected with Tom and that their projects are out of sync. The plugin gives them each the option of using Tom’s file versions, Todd’s files, or performing a git pull request. They both do a git pull and are back in sync.

Todd quickly opens the User model in Rubymine with cmd-shift-N and Todd quickly sees that same file opened in Textmate. Todd then highlights a method that has been failing a test and Tom sees that highlight. Todd makes the change to the file, clicks cmd-s, and that file change is synced over to Tom.

Tom thought there was a secondary change needed in the Profile model, so he hits cmd-T, opens the Profile model and Todd sees that file opened in Rubymine. Todd tells Tom that he’s smoking catn