Skip to content

Instantly share code, notes, and snippets.

View raunakdoesdev's full-sized avatar

Raunak Chowdhuri raunakdoesdev

View GitHub Profile
@raunakdoesdev
raunakdoesdev / researchReadyComputer.sh
Last active May 5, 2017 01:44
Script to get computer up and running for neural net research.
######################################################################
# Notes:
# Made for Ubuntu 16.04 computer that supports CUDA 8.0
######################################################################
# Setup Vim
sudo apt-get install vim curl
curl https://raw.githubusercontent.com/sauhaardac/ConfigFiles/master/.vimrc > ~/.vimrc
cd ~
@raunakdoesdev
raunakdoesdev / setup_tx1.sh
Last active February 18, 2019 13:17
Sets up TX1/TX2 w/ PyTorch Inference Environment
# Run this after a fresh flashing of JetPack 3.0 on a Jetson TX1
# NEED TO BE LOGGED INTO TO nvidia USER ACCOUNT WITH PASSWORD OF: nvidia
sudo c_rehash /etc/ssl/certs
sudo dhclient wlan0
############################# Install Karl's Repository #############################
sudo apt-get --assume-yes install git
git clone https://github.com/karlzipser/kzpy3.2.git kzpy3
@raunakdoesdev
raunakdoesdev / flash.sh
Last active July 27, 2017 06:35
TX2 Cloning Process
#!/bin/bash
# Copyright (c) 2011-2017, NVIDIA CORPORATION. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions
# are met:
# * Redistributions of source code must retain the above copyright
# notice, this list of conditions and the following disclaimer.
# * Redistributions in binary form must reproduce the above copyright
@raunakdoesdev
raunakdoesdev / sshd_config
Last active July 31, 2017 22:04
Secure SSHD Config
# Package generated configuration file
# See the sshd_config(5) manpage for details
# What ports, IPs and protocols we listen for
Port 1022
# Use these options to restrict which interfaces/protocols sshd will bind to
#ListenAddress ::
#ListenAddress 0.0.0.0
Protocol 2
# HostKeys for protocol version 2
@raunakdoesdev
raunakdoesdev / bdd-docker
Created August 16, 2017 18:49
Docker Wrapper
nvidia-docker run -it -v /:/hostroot -w /hostroot/$PWD tpankaj/bdd-pytorch $@
# The data, shuffled and split between train and test sets:
(x_train, y_train), (x_test, y_test) = cifar10.load_data()
x_train = x_train[0:5000]
y_train = y_train[0:5000]
x_test = x_test[0:1000]
y_test = y_test[0:1000]
@raunakdoesdev
raunakdoesdev / raga_train.py
Created June 23, 2018 22:07
Code for training music detector.
from os import listdir
from os.path import isfile, join
import os
import json
import progressbar
from multiprocessing import Pool
import time, tqdm, random
from collections import deque
import numpy as np
from sseclient import SSEClient
import requests
from queue import Queue
import json
import threading
import socket
class ClosableSSEClient(SSEClient):
20.9.21.223
BufferedReader f = new BufferedReader(new FileReader("maze"));
StringTokenizer st = new StringTokenizer(f.readLine());
int r = Integer.parseInt(st.nextToken());
int c = Integer.parseInt(st.nextToken());
String maze[][] = new String[r][c];
Deque<Point> q = new LinkedList<Point>();
try {
if (arg.incoordinate) {