To turn off messages like:
Info in <TCanvas::Print>: png file my_plot.png has been created
add in:
gErrorIgnoreLevel = kWarning
To turn off messages like:
Info in <TCanvas::Print>: png file my_plot.png has been created
add in:
gErrorIgnoreLevel = kWarning
#!/usr/bin/env python | |
""" | |
Go through TeX files and count words, plot things. | |
TODO: | |
- improve timezone handling | |
- only count commits where tex file changed? | |
- add PDF pagecount? | |
""" |
[color] | |
ui = true | |
[alias] | |
b = branch | |
ca = commit --amend | |
can = commit --amend --no-edit | |
co = checkout | |
cb = checkout -b | |
cp = cherry-pick | |
cpc = cherry-pick --continue |
" activates filetype detection | |
filetype plugin indent on | |
" activates syntax highlighting among other things | |
syntax on | |
" The width of a TAB is set to 4. | |
" Still it is a \t. It is just that | |
" Vim will interpret it to be having | |
" a width of 4. |
{ | |
"added_words": | |
[ | |
"diboson", | |
"Majorana", | |
"Higgs", | |
"collider", | |
"hadronic", | |
"leptonic", | |
"Feynman", |
import sys | |
import types | |
def list_import_versions(): | |
imports = [] | |
for val in globals().values(): | |
if isinstance(val, types.ModuleType) and val.__name__ != 'builtins': | |
full_name = val.__name__ | |
version = getattr(sys.modules[full_name], '__version__', None) # skips builtins | |
if version: |
#include <iostream> | |
#include <vector> | |
using namespace std; | |
class A { | |
public: | |
A(): thing(nullptr) {} |
#!/usr/bin/env python | |
"""Look for "bad" directories with duplicate files (xxx.mp3 vs xxx 1.mp3), | |
empties, only artwork, etc | |
""" | |
import os | |
import re |
#!/usr/bin/env python | |
""" | |
Get the Github Pull Request unique ID. | |
Needed for posting comments, etc | |
""" | |
from __future__ import print_function | |
import json |
def plot_two_hists(var, df1, df2, title1, title2, xlabel, ylabel, **kwargs): | |
"""function to make 2 side-by-side hists to compare 2 dataframes""" | |
fig2, ax2 = plt.subplots(nrows=1, ncols=2) | |
fig2.set_size_inches(24, 8) | |
plt.subplots_adjust(wspace=0.2) | |
df1[var].plot(kind="hist", ax=ax2[0], title=title1, **kwargs) | |
ax2[0].set_xlabel(xlabel) | |
ax2[0].set_ylabel(ylabel) |