Skip to content

Instantly share code, notes, and snippets.

@YashasSamaga
YashasSamaga / gist:8f264a28cde4b1d6af78865e81790c6e
Last active February 4, 2017 13:11
Char bit pattern to string lookup table
static const char bstring_tlb256[256][9] =
{
"00000000",
"00000001",
"00000010",
"00000011",
"00000100",
"00000101",
"00000110",
"00000111",
#include <iostream>
#include <vector>
#include <algorithm>
using namespace std;
int cases, note_count, required_money;
//cases - no of cases
//note_count - no of notes
//required money - money asked by the monster
#include <iostream>
#include <iomanip>
#include <vector>
#include <functional>
#include <cmath>
typedef long double Type;
constexpr Type eps = 1E-12;
using analysisFunction = std::function<const Type(const Type, const Type)>;
/*
** PAWN Library Extension (PLE)
**
** Chrono
** Time library
**
** This file is part of PAWN Library Extension.
**
** This library is free software: you can redistribute it and/or modify
** it under the terms of the GNU General Public License as published by
#!/bin/bash
echo 1000000 15
for((i = 0; i < 200000; i++))
do
echo "A $RANDOM"$(($RANDOM/100))
echo 'H'
done
for((i = 0; i < 600000; i++))
do
#include <iostream>
#include <queue>
#include <functional>
#define DEBUG
using GraphData = typename std::vector<int>;
using Graph = typename std::vector<std::vector<int>>;
void BFS(const GraphData& gdata, const Graph& graph) {
@YashasSamaga
YashasSamaga / main.py
Last active December 18, 2023 23:49
GSoC 2018 List of selected students
import requests
import json
fetch_url = "https://summerofcode.withgoogle.com/api/program/current/project/?page={}&page_size=100"
fetch_params = [pageno for pageno in range(1,14)]
searchList = []
with open("nameList.txt", "r") as inFile:
for line in inFile:
searchList += [line.lower().split()]
raw positive vectors: 2900, transformed positive vectors: 174
training samples: 139
raw negative vectors: 4153, transformed negative vectors: 170
training samples: 136
Aggregate parameter(s) statistics:
positive field 0:
average: 0.098596, stddev: 0.0324172
min: 0.0362827, max: 0.239384
#include "main.h"
#include <dlib/dnn.h>
#include <sampml/svm_classifier.hpp>
#include "tools/fixed_thread_pool.hpp"
#include "iscript.hpp"
#include "classifier.hpp"
#include "transform.hpp"
#include "dnn.hpp"
#include <iostream>
#include <algorithm>
#include <fstream>
#include <vector>
#include <chrono>
#include <opencv2/dnn.hpp>
#include <opencv2/highgui.hpp>
#include "benchmark.hpp"