This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Essentials ########################################################### | |
| unbind C-b | |
| set -g prefix C-q | |
| # Reload config | |
| bind R source-file ~/.tmux.conf \; display-message "Tmux configuration reloaded" | |
| # Basic terminal defaults | |
| setw -g mode-keys vi |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| cmake_minimum_required(VERSION 3.10) | |
| project(cppgen VERSION 0.0.1 LANGUAGES CXX) | |
| set(CMAKE_CXX_STANDARD 11) | |
| set(CMAKE_CXX_STANDARD_REQUIRED ON) | |
| add_executable(remapping remapping.cc) | |
| target_link_libraries(remapping stdc++ "-framework Foundation" "-framework IOKit" objc) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| cmake_minimum_required(VERSION 3.10) | |
| project(cppgen VERSION 0.0.1 LANGUAGES CXX) | |
| set(CMAKE_CXX_STANDARD 11) | |
| set(CMAKE_CXX_STANDARD_REQUIRED ON) | |
| link_libraries(pthread) | |
| add_executable(cppgen cppgen.cc) | |
| add_executable(cppgen-dup2 cppgen-dup2.cc) | |
| add_executable(cppgen-lock cppgen-lock.cc) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| with 0 points | |
| with 160 points | |
| with 60 points | |
| with 140 points | |
| with 64 points | |
| with 52 points | |
| with 84 points | |
| with 146 points | |
| with 52 points | |
| with 76 points |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include "skel.h" | |
| #include <torch/extension.h> | |
| namespace py = pybind11; | |
| PYBIND11_MODULE(skel, m) { | |
| py::class_<Skel>(m, "Skel").def(py::init<>()).def("tensor", &Skel::tensor) | |
| /**/ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import timeit | |
| import torch | |
| from torch import nn | |
| from torch.nn import functional as F | |
| class Flags: | |
| pass |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Copied from | |
| // https://raw.githubusercontent.com/tensorflow/tensorflow/9590c4c32dd4346ea5c35673336f5912c6072bf2/tensorflow/core/platform/default/notification.h | |
| // and slightly modified. | |
| /* Copyright 2015 The TensorFlow Authors. All Rights Reserved. | |
| Licensed under the Apache License, Version 2.0 (the "License"); | |
| you may not use this file except in compliance with the License. | |
| You may obtain a copy of the License at | |
| http://www.apache.org/licenses/LICENSE-2.0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import os | |
| import select | |
| import sys | |
| import termios | |
| import gym | |
| def play(): | |
| env = gym.make("AdventureNoFrameskip-v4" if len(sys.argv) < 2 else sys.argv[1]) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import os | |
| import sys | |
| import tensorflow as tf | |
| logdir = "/tmp/checkpoints" | |
| def get_variables(logdir): | |
| variables = {} |