Skip to content

Instantly share code, notes, and snippets.

Jaan Tollander de Balsch jaantollander

Block or report user

Report or block jaantollander

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 sympy_examples.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@jaantollander
jaantollander / notes.md
Created Dec 29, 2017
Web development course exam practice notes
View notes.md

HTML

Tags & Structure

Basic HTML Structure

<!DOCTYPE html>
<html>
  <head>
    <title>title</title>
    <meta> ... </meta>
    <link> ... </link>
@jaantollander
jaantollander / unicodesymbols.csv
Last active Dec 29, 2017
List of unicode math symbols (separator uses ^)
View unicodesymbols.csv
We can make this file beautiful and searchable if this error is corrected: It looks like row 7 should actually have 1 column, instead of 2. in line 6.
# Unicode characters and corresponding LaTeX math mode commands
# *************************************************************
#
# :Copyright: © 2011 Günter Milde
# :Date: Last revised 2011-11-08
# :Licence: This work may be distributed and/or modified under the
# conditions of the `LaTeX Project Public License`_,
# either version 1.3 of this license or (at your option)
# any later version.
#
@jaantollander
jaantollander / make_docs.py
Last active Jul 18, 2017
Livereload Sphinx
View make_docs.py
#!/usr/bin/env python
from livereload import Server, shell
package = "<package name>"
server = Server()
server.watch('docs/*.rst', shell('make html', cwd='docs'))
server.watch('docs/**/*.rst', shell('make html', cwd='docs'))
server.watch(f'{package}/**/*.py', shell('make html', cwd='docs'))
server.watch(f'{package}/*.py', shell('make html', cwd='docs'))
server.serve(root='docs/_build/html')
@jaantollander
jaantollander / conf.py
Last active Jul 8, 2017
Sphinx configuration file example
View conf.py
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""
This file is execfile()d with the current directory set to its
containing dir.
Note that not all possible configuration values are present in this
autogenerated file.
All configuration values have a default; values that are commented out
serve to show the default.
requirements:
@jaantollander
jaantollander / lprof.py
Created Jun 1, 2017
How to use Python line_profiler programatically
View lprof.py
"""How to use line profiler [1]_ programatically. Code adapted from [2]_.
.. [1] https://github.com/rkern/line_profiler
.. [2] https://nvbn.github.io/2017/05/29/complexity/
"""
from line_profiler import LineProfiler
def main(*args, **kwargs):
"""Function to be profiled"""
@jaantollander
jaantollander / patterns.py
Last active May 21, 2017
Pycharm live templates for various Python patterns
View patterns.py
# Pytest
def test_$NAME$():
assert True$END$
# Traitlets
@default('$NAME$')
def _default_$NAME$(self):
return $END$
View classifiers.txt
Development Status :: 1 - Planning
Development Status :: 2 - Pre-Alpha
Development Status :: 3 - Alpha
Development Status :: 4 - Beta
Development Status :: 5 - Production/Stable
Development Status :: 6 - Mature
Development Status :: 7 - Inactive
Environment :: Console
Environment :: Console :: Curses
Environment :: Console :: Framebuffer
@jaantollander
jaantollander / geometry.py
Last active Apr 17, 2017
Converting shapely geometries to other objects
View geometry.py
"""Convert shapely geometries to other objects
Other interfaces
- matplotlib: PathPatch
- pyqtgraph: PlotItem
- bokeh: Glyph
- scikit-image: Indices on a grid
References
@jaantollander
jaantollander / bash-cheatsheet.sh
Created Mar 23, 2017 — forked from LeCoupa/bash-cheatsheet.sh
Bash CheatSheet for UNIX Systems
View bash-cheatsheet.sh
#!/bin/bash
#####################################################
# Name: Bash CheatSheet for Mac OSX
#
# A little overlook of the Bash basics
#
# Usage:
#
# Author: J. Le Coupanec
# Date: 2014/11/04
You can’t perform that action at this time.