Skip to content

Instantly share code, notes, and snippets.

View lordlycastle's full-sized avatar
🤙
Let it Fly!

lordlycastle

🤙
Let it Fly!
View GitHub Profile
# coding: utf-8
# In[14]:
import numpy as np
import pandas as pd
from plotly.offline import download_plotlyjs, init_notebook_mode, iplot, plot
init_notebook_mode(connected=True)

下面是一堆awesome-*列表轮子,想看干货的童靴可以随意打开一个轮子:

  • Awesome - A curated list of awesome lists
  • awesome-all – A curated list of awesome lists of awesome frameworks, libraries and software
  • awesome-awesome by @emijrp – A curated list of awesome curated lists of many topics.
  • awesome-awesome by @erichs – A curated list of awesome curated lists! Inspired by inspiration.
  • awesome-awesome by @oyvindrobertsen – A curated list of curated lists of libraries, resources and shiny things for various languages.
  • awesome-awesomeness – A curated list of awesome awesomeness
  • awesome-awesomes – Awesome collection of awesome lists of libraries, tools, frameworks and software for any programming language
//Shader imported from https://docs.chaosgroup.com/display/OSLShaders/Thin+Film+Shader
Shader "Custom/ThinFilmIridescence" {
Properties {
_Color ("Color", Color) = (1,1,1,1)
_MainTex ("Albedo (RGB)", 2D) = "white" {}
[Normal]_Normal("Normal", 2D) = "bump" {}
_Glossiness ("Smoothness", Range(0,1)) = 0.5
_Metallic ("Metallic", Range(0,1)) = 0.0
_ThicknessMin("ThicknessMin", float) = 250
_ThicknessMax("ThicknessMax", float) = 400
@lordlycastle
lordlycastle / mergesort.js
Created January 9, 2020 13:24 — forked from schadokar/mergesort.js
Merge Sort Algorithm in javascript
/**
* ************************************************ MERGE SORT *****************************************************
*
* [38, 27, 43, 3, 9, 82, 10, 900, 78, 80, 11]
* / \
* [38, 27, 43, 3, 9, 82] [10, 900, 78, 80, 11]
* / \ / \
* [38, 27, 43] [3, 9, 82] [10, 900, 78] [ 80, 11 ]
* / \ / \ / \ / \
* [38, 27] [ 43 ] [3, 9] [ 82 ] [10, 900] [ 78 ] [ 80 ] [ 11 ]
@lordlycastle
lordlycastle / asciidoc-static.adoc
Created January 9, 2020 19:31 — forked from briandominick/asciidoc-static.adoc
Static Site Generators with AsciiDoc Support

There are 19 static site generators that support AsciiDoc sourcing.

@lordlycastle
lordlycastle / ipython_notebook_in_git.md
Created May 14, 2020 17:38 — forked from pbugnion/ ipython_notebook_in_git.md
Keeping IPython notebooks under Git version control

This gist lets you keep IPython notebooks in git repositories. It tells git to ignore prompt numbers and program outputs when checking that a file has changed.

To use the script, follow the instructions given in the script's docstring.

For further details, read this blogpost.

The procedure outlined here is inspired by this answer on Stack Overflow.

@lordlycastle
lordlycastle / OdinWatchWindow.cs
Created June 18, 2020 20:05 — forked from Froghut/OdinWatchWindow.cs
Odin Watch Window
#if ODIN_INSPECTOR
using System;
using System.Collections.Generic;
using System.Linq;
using Sirenix.OdinInspector.Editor;
using Sirenix.Utilities;
using Sirenix.Utilities.Editor;
using UnityEditor;
using UnityEngine;
using Object = UnityEngine.Object;
@lordlycastle
lordlycastle / osx_setup.sh
Created June 23, 2020 10:36 — forked from dannysmith/osx_setup.sh
Sensible defaults for New Mac
#!/usr/bin/env bash
# ~/.osx — http://mths.be/osx
# Ask for the administrator password upfront
sudo -v
# Keep-alive: update existing `sudo` time stamp until `.osx` has finished
while true; do sudo -n true; sleep 60; kill -0 "$$" || exit; done 2>/dev/null &
@lordlycastle
lordlycastle / latex documentation.txt
Last active June 29, 2020 12:02 — forked from kadrach/gist:6228314
Enabling texdoc: Texlive/BasicTeX
Found here: http://macosx-tex.576846.n2.nabble.com/BasicTeX-and-documentation-td7579224.html
Problem: BasicTex does not come with texdoc installed, and does not build docs by default
1. Install texdoc
> tlmgr install texdoc
2. Enable automatic build of documentation, which is disabled (default) for BasicTeX tlmgr.
> tlmgr option docfiles 1
var fs = require('fs'),
Converter = require('swagger2-postman2-converter');
function handleConversion(originalFileName, newFileName) {
// read the local swagger file
var swaggerObject = JSON.parse(
fs.readFileSync(originalFileName, 'utf8')
);