Skip to content

Instantly share code, notes, and snippets.

#include "SDL2/SDL.h"
#include "SDL2/SDL_opengl.h"
#include <fstream>
namespace shaders {
const GLchar* read_shader_source(const std::string shaderpath) {
std::ifstream in(shaderpath);
std::string contents((std::istreambuf_iterator<char>(in)),
[ 14%] Building CXX object CMakeFiles/smargl.dir/Triangle.cpp.o
In file included from /usr/include/x86_64-linux-gnu/c++/5/bits/c++allocator.h:33:0,
from /usr/include/c++/5/bits/allocator.h:46,
from /usr/include/c++/5/string:41,
from /usr/include/c++/5/bits/locale_classes.h:40,
from /usr/include/c++/5/bits/ios_base.h:41,
from /usr/include/c++/5/ios:42,
from /usr/include/c++/5/istream:38,
from /usr/include/c++/5/fstream:38,
from /home/anish/Code/smargl_tst/shader.h:7,
#define GLFW_INCLUDE_VULKAN
#include <GLFW/glfw3.h>
#include <iostream>
#include <stdexcept>
#include <functional>
#include <algorithm>
#include <vector>
#include <cstring>
#include <set>
#define GLFW_INCLUDE_VULKAN
#include <GLFW/glfw3.h>
#include <iostream>
#include <stdexcept>
#include <functional>
#include <fstream>
#include <algorithm>
#include <vector>
#include <cstring>
from __future__ import print_function
from common import *
from callbacks import *
from listeners import *
import argparse
import atexit
import socket
error: expected one of `,`, `.`, `?`, `else`, or `}`, found `ClearValue`
--> /home/anish/Code/vulkano/vulkano/src/command_buffer/auto.rs:520:33
|
519 | }
| - expected one of `,`, `.`, `?`, `else`, or `}` here
520 | ClearValue::Int(_) => if atch_desc.format.ty() != FormatTy::Sint {
| ^^^^^^^^^^ unexpected token
import tensorflow as tf
import numpy as np
import cProfile
def ff_network(name, layer_dims):
layer_weight_list = [None] * len(layer_dims)
layers = [None] * len(layer_dims)
layers[0] = tf.placeholder('float', [None, layer_dims[0]])
layer_weight_list = [None] * (len(layer_dims) - 1)
layer_bias_list = [None] * len(layer_weight_list)
import tensorflow as tf
import numpy as np
import gym
def ff_network(name, layer_dims):
layer_weight_list = [None] * len(layer_dims)
layers = [None] * len(layer_dims)
layers[0] = tf.placeholder('float', [None, layer_dims[0]])
layer_weight_list = [None] * (len(layer_dims) - 1)
;; Reader macro for hash tables
;; Following code modified from https://news.ycombinator.com/item?id=1611090
(labels ((in-place-hash (stream char)
(declare (ignore char))
(let ((ls (read-delimited-list #\} stream t)))
(with-gensyms (table)
`(let ( (,table (make-hash-table :test #'equalp)))
,@(mapcar (lambda (p) `(setf (gethash ,(car p) ,table) ,(cadr p)))
ls)
@anlsh
anlsh / yodakenobi-revelations-review
Created May 6, 2020 01:58
YodaKenboi dissects Revelations and talks about Karen Traviss & Mandalorians in Star Wars
Post by user YodaKenobi on boards.theforce.net
Original url was http://boards.theforce.net/literature/b10003/28128642/p5 which is now 404'd
The post remains accessible at https://web.archive.org/web/20090917025847/http://boards.theforce.net/literature/b10003/28128642/p5
Post tagline: Date Posted: 3/2/08 6:50pm Subject: RE: The JC Lit Reviews Special: LEGACY OF THE FORCE: REVELATION (Spoilers) - Date Edited: 3/2/08 8:03pm (2 edits total) Edited By: YodaKenobi
Original post content follows
==================================================================================
I'll apologize now for the length of this post, but I have a lot I wanted to say and I want to explain this as clearly as possible. I've divided this review up in more sections than I normally would, simply because I'm afraid it becomes a jumble otherwise.