Skip to content

Instantly share code, notes, and snippets.

Sameed Pervaiz greenbagels

Block or report user

Report or block greenbagels

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View opencl_transply.c
#include <stdio.h>
#include <time.h>
#include <stdlib.h>
#define CL_USE_DEPRECATED_OPENCL_1_2_APIS
#include <CL/cl.h>
const char* kern_src =
"kernel void para_transply(global double *input, global double *output)\n"
"{\n"
" int i = get_global_id(0);\n"
View keybase.md

Keybase proof

I hereby claim:

  • I am greenbagels on github.
  • I am greenbagels (https://keybase.io/greenbagels) on keybase.
  • I have a public key ASD5spdm1QHIaKqvs1d1ddBoKP1FHlgdKtec-lZfEpQTFwo

To claim this, I am signing this object:

View gist:0fbde5a679fa7d497d8bb90f8d44e04c
Advocacy
Empowering
Spreading awareness on campus
Empowering the survivors
Staunch defenders of liberty
Casting a light on modern day slavery by spreading awareness on campus, empowering survivors through legal advocacy and story-telling,
story-telling
diseminating stories
@greenbagels
greenbagels / kiln_shopping_list.sql
Created Jul 5, 2017
Script that sets up a shopping list for a homemade kiln
View kiln_shopping_list.sql
CREATE TABLE list
(
item varchar(255) NOT NULL,
unit_price numeric(6,2) NOT NULL,
quantity integer NOT NULL,
total numeric(6,2) NULL,
source varchar(255) NOT NULL,
);
INSERT INTO list (item, unit_price, quantity, source)
@greenbagels
greenbagels / .config.diff
Last active Jul 3, 2017
linux 4.11.8 -> 4.12.0 differences (from `make silentoldconfig`) (note, unselected parent options may cause some changes to not show, this is NOT a definitive changelog.)
View .config.diff
+ Kyber I/O scheduler (MQ_IOSCHED_KYBER) [Y/n/m/?] (NEW)
+ BFQ I/O scheduler (IOSCHED_BFQ) [N/m/y/?] (NEW)
Intel SoC IOSF Sideband support for SoC platforms (IOSF_MBI) [M/y/?] m
+ Enable IOSF sideband access through debugfs (IOSF_MBI_DEBUG) [N/y/?] (NEW)
Machine Check / overheating reporting (X86_MCE) [Y/n/?] y
+ Support for deprecated /dev/mcelog character device (X86_MCELOG_LEGACY) [N/y/?] (NEW)
@greenbagels
greenbagels / roll.rb
Last active Jun 29, 2017
simulates dice rolling
View roll.rb
#!/usr/bin/env ruby
puts "Enter a dice roll in the form 'PdQ'"
input = /(\d+)d(\d+)/.match(gets).values_at(1,2).map!{&:to_i}
total = (1..input[0]).map{|idx| rand(input[1]) + 1}.each{|num| puts "You rolled #{num}"}.reduce(:+)
puts "You totaled #{total}"
View deptree.txt
Dependency Tree for CSE 5441 (Approved): Introduction to Parallel Computing:
[CSE 5441: Introduction to Parallel Computing]
[CSE 2421: Systems I: Introduction to Low-Level Programming and Computer Organization]
[CSE 2321: Foundations I: Discrete Structures] (Coreq with 2231)
[CSE 2231: Software II: Software Development and Design] (Coreq with 2321)
[CSE 2221: Software I: Software Components]
View deptree.txt
Dependency Tree for CSE 5441 (Approved): Introduction to Parallel Computing:
[CSE 5441: Introduction to Parallel Computing]
[CSE 2421: Systems I: Introduction to Low-Level Programming and Computer Organization]
[CSE 2321: Foundations I: Discrete Structures] (Coreq with 2231)
[CSE 2231: Software II: Software Development and Design] (Coreq with 2321)
[CSE 2221: Software I: Software Components]
View readable.cpp
#include <cctype>
#include <iostream>
#include <type_traits>
#include <typeinfo>
namespace ascii
{
template <typename T, T operand, typename std::enable_if<std::is_same<T,char>::value, int>::type = 0>
class get_lower
{
View random.hpp
#ifndef XORSHIFT_H
#define XORSHIFT_H
#include <cstddef> //std::size_type
#include <limits> //std::numeric_limits
namespace xor
{
namespace detail
{
You can’t perform that action at this time.