Skip to content

Instantly share code, notes, and snippets.

View Slabity's full-sized avatar

Slabity Slabity

View GitHub Profile
with import <nixpkgs> { };
stdenv.mkDerivation rec {
name = "Rust";
buildInputs = [
rustChannels.nightly.rust
vulkan-loader
vulkan-headers
cmake
[package]
name = "nix-parser"
version = "0.1.0"
authors = ["Tyler Slabinski <tslabinski@slabity.net>"]
[dependencies.rnix]
git = "https://gitlab.com/jD91mZM2/rnix.git"
[dependencies]
arenatree = "0.1.0"
;;; xresources-theme.el --- Use your .Xresources as your emacs theme
;; Copyright (C) 2014-2014 Marten Lienen <marten.lienen@gmail.com>
;; Author: Marten Lienen <marten.lienen@gmail.com>
;; Keywords: xresources, theme
;; Version: 0.2.0
;; This file is not part of GNU Emacs.
;; -*- mode: emacs-lisp -*-
;; This file is loaded by Spacemacs at startup.
;; It must be stored in your home directory.
(defun dotspacemacs/layers ()
"Layer configuration:
This function should only modify configuration layer settings."
(setq-default
;; Base distribution to use. This is a layer contained in the directory
;; `+distribution'. For now available distributions are `spacemacs-base'
#[macro_use]
extern crate nom;
use nom::*;
named! {
parse_str<&str, &str>,
delimited!(
char!('"'),
escaped!(
;;; xresources-theme.el --- Use your .Xresources as your emacs theme
;; Copyright (C) 2014-2014 Marten Lienen <marten.lienen@gmail.com>
;; Author: Marten Lienen <marten.lienen@gmail.com>
;; Keywords: xresources, theme
;; Version: 0.2.0
;; This file is not part of GNU Emacs.
;; -*- mode: emacs-lisp -*-
;; This file is loaded by Spacemacs at startup.
;; It must be stored in your home directory.
(defun dotspacemacs/layers ()
"Layer configuration:
This function should only modify configuration layer settings."
(setq-default
;; Base distribution to use. This is a layer contained in the directory
;; `+distribution'. For now available distributions are `spacemacs-base'
@Slabity
Slabity / DRM-API.md
Last active September 4, 2018 20:43

DRM API

Nonlegacy

GEM

  • DRM_IOCTL_GEM_CLOSE
  • DRM_IOCTL_GEM_FLINK
  • DRM_IOCTL_GEM_OPEN

PRIME Handle/FD

{% include './types.yml' %}
syscall: &syscall
type: syscall
args: []
return: c_int
open:
<<: *syscall
args:
import tensorflow as tf
import numpy as np
from tensorflow.examples.tutorials.mnist import input_data
mnist = input_data.read_data_sets("MNIST_data/", one_hot=True)
nhidden = 500
nvisible = 784
x = tf.placeholder(tf.float32, [None, nvisible])