Skip to content

Instantly share code, notes, and snippets.

@antnieszka
antnieszka / dallas.zsh-theme
Last active August 29, 2015 14:22
Dallas theme for oh-my-zsh
# Personalized!
# Grab the current date (%D) and time (%T) wrapped in {}: {%D %T}
DALLAS_CURRENT_TIME_="%{$fg[white]%}{%{$fg[yellow]%}%D %T%{$fg[white]%}}%{$reset_color%}"
# Grab the current version of ruby in use (via RVM): [ruby-1.8.7]
if [ -e ~/.rvm/bin/rvm-prompt ]; then
DALLAS_CURRENT_RUBY_="%{$fg[white]%}[%{$fg[magenta]%}\$(~/.rvm/bin/rvm-prompt i v)%{$fg[white]%}]%{$reset_color%}"
else
if which rbenv &> /dev/null; then
DALLAS_CURRENT_RUBY_="%{$fg[white]%}[%{$fg[magenta]%}\$(rbenv version | sed -e 's/ (set.*$//')%{$fg[white]%}]%{$reset_color%}"
Traceback (most recent call last):
File "/home/ant6/INZ/modulators/src/findworker.py", line 411, in run
self.plot_functions()
File "/home/ant6/INZ/modulators/src/findworker.py", line 464, in plot_functions
show=common.check_option('show_sobp_plot'))
File "/home/ant6/INZ/modulators/src/plotting.py", line 122, in plot_SOBP
pylab.savefig(filename + '.' + plot_format, format=plot_format)
File "/usr/lib/python3/dist-packages/matplotlib/pyplot.py", line 561, in savefig
return fig.savefig(*args, **kwargs)
File "/usr/lib/python3/dist-packages/matplotlib/figure.py", line 1422, in savefig
0 0.0
11.2135919357 0.0
11.2135919357 1.31920580374
15.4180208471 1.31920580374
15.4180208471 2.63841160748
19.4046196536 2.63841160748
19.4046196536 3.95761741123
22.707522112 3.95761741123
22.707522112 5.27682321497
25.948042535 5.27682321497
(beprof3){16-07-02 18:49} ~/Downloads ant6% ➜ rm -fr beprof
(beprof3){16-07-02 18:49} ~/Downloads ant6% ➜ git clone https://github.com/ant6/beprof.git
Cloning into 'beprof'...
remote: Counting objects: 654, done.
remote: Total 654 (delta 0), reused 0 (delta 0), pack-reused 654
Receiving objects: 100% (654/654), 155.03 KiB | 174.00 KiB/s, done.
Resolving deltas: 100% (366/366), done.
Checking connectivity... done.
(beprof3){16-07-02 18:49} ~/Downloads ant6% ➜ cd beprof
(beprof3){16-07-02 18:49} ~/Downloads/beprof@master ant6% ➜ python setup.py develop
# TO2 - projekt?
TO2 = False
with open("1-department-list.csv", "r", encoding="utf8") as depart_in:
przedmioty = ()
studenciaki = {}
temp_student = ""
for e in depart_in.readlines():
if e[0] != '\t': # pewno student
temp_student = e.strip().split(";")[0]
import numpy as np
import scipy.optimize
import beprof.profile
import logging
# logging = logging.getLogger()
# logging.setLevel(30)
# nbps = 3
>>> t = getattr(mcpartools.scheduler.torque, "Torque")
>>> t
<class 'mcpartools.scheduler.torque.Torque'>
>>> b
'torque'
>>> b.title()
'Torque'
>>> t = getattr(mcpartools.scheduler.torque, b.title())
>>> t.__name__
'Torque'

Keybase proof

I hereby claim:

  • I am ant6 on github.
  • I am ant6 (https://keybase.io/ant6) on keybase.
  • I have a public key ASDhM29FBMjXFGk4GmzDWF2OPguwR1Wxw8Yn7HSTxq0SkQo

To claim this, I am signing this object:

@antnieszka
antnieszka / gulpfile.js
Created March 12, 2018 20:26
Simple gulpfile for django projects
var gulp = require('gulp');
var browserSync = require('browser-sync');
var reload = browserSync.reload;
gulp.task('default', function () {
browserSync.init({
notify: true,
proxy: "localhost:8000",
ghostMode: false,
reloadDebounce: 500
@antnieszka
antnieszka / fields.py
Created May 14, 2018 20:15
EnglishURLField
from django.db.models import CharField
from django.utils.text import slugify
import logging
logger = logging.getLogger(__name__)
class EnglishURLField(CharField):
def __init__(self, *args, **kwargs):