Skip to content

Instantly share code, notes, and snippets.

@scopatz
scopatz / genpowe.ipynb
Created March 2, 2015 23:14
Genereated Power from FRforward.xml
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@scopatz
scopatz / physics.code-install-step2.sh
Created December 23, 2014 22:03
physics.code-install-step2
# On Linux, Use the following to install Miniconda:
$ conda install --yes numpy scipy ipython ipython-notebook matplotlib pandas \
pytables nose setuptools sphinx mpi4py
@scopatz
scopatz / physics.code-install-step1.sh
Last active August 29, 2015 14:12
physics.code-install-step1
# On Linux, Use the following to install Miniconda:
$ bash ~/Downloads/Miniconda-3.7.0-Linux-x86_64.sh
# On MacOSX, Use the following to install Miniconda:
$ bash ~/Downloads/Miniconda3-3.7.0-MacOSX-x86_64.sh
@scopatz
scopatz / timing
Created November 30, 2014 19:21
bool timings
In [1]: x = True
In [2]: %timeit 1 if x else 0
10000000 loops, best of 3: 36.8 ns per loop
In [3]: %timeit 1 if x is True else 0
10000000 loops, best of 3: 44.7 ns per loop
In [4]: %timeit 1 if x == True else 0
10000000 loops, best of 3: 55.2 ns per loop
@scopatz
scopatz / ant -v
Created October 13, 2014 15:30
cyclist mac build failure
Anthonys-MacBook-Air:work scopatz$ ant -v
Apache Ant(TM) version 1.9.4 compiled on October 13 2014
Trying the default build file: build.xml
Buildfile: /Users/scopatz/miniconda/conda-bld/work/build.xml
Detected Java version: 1.6 in: /System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Home
Detected OS: Mac OS X
parsing buildfile /Users/scopatz/miniconda/conda-bld/work/build.xml with URI = file:/Users/scopatz/miniconda/conda-bld/work/build.xml
Project base dir set to: /Users/scopatz/miniconda/conda-bld/work
Build sequence for target(s) `dist' is [setup-staging-area, compile, init-fx-tasks, dist]
Complete build sequence is [setup-staging-area, compile, init-fx-tasks, dist, app, ]
@scopatz
scopatz / fails-materials.xml
Created August 5, 2014 22:22
OpenMC Material Failure
<materials>
<default_xs>71c</default_xs>
<material id="1">
<density value="10.7" units="g/cc"/>
<nuclide name="U-235" wo="0.04"/>
<nuclide name="U-238" wo="0.96"/>
</material>
<material id="2">
<density value="0.73" units="g/cc"/>
<nuclide name="H-1" wo="0.111074453148"/>
@scopatz
scopatz / stdout
Created May 27, 2014 14:09
cyclus clang
copatz@ares ~/cyclus gidden-atbuild $ export CXX=/usr/bin/clang
scopatz@ares ~/cyclus gidden-atbuild $ export CXX=/usr/bin/clang++
scopatz@ares ~/cyclus gidden-atbuild $ rm -r build/
rm: cannot remove ‘build/’: No such file or directory
scopatz@ares ~/cyclus gidden-atbuild $ ./install.py --build_type=Debug -j 4
/usr/bin/cmake
-- The C compiler identification is Clang 3.4.0
-- The CXX compiler identification is Clang 3.4.0
-- Check for working C compiler: /usr/bin/clang
-- Check for working C compiler: /usr/bin/clang -- works
scopatz@ares ~/pyne/tests staging $
scopatz@ares ~/pyne/tests staging $ nosetests
.....................................................................................................................Requested faceting tolerance: 0
Using faceting tolerance: 0.001
The implicit complement bounds 6 surfaces
The implicit complement's total surface area = 431.475
.....................................................F...................F.......................................................F................................................................................................................................................................................................................................................................................................................................................................................Requested faceting tolerance: 0
Using faceting tolerance: 0.001
..Requested faceting tolerance: 0
Using faceting tolerance: 0.001
scopatz@ares ~/xdress/tests gidden-pair $ nosetests
........F...........................................................................................................................................................................................................................................................................................................................................................
======================================================================
FAIL: test_cppproj.test_all('PYTHONPATH="/home/scopatz/xdress" /usr/bin/python /home/scopatz/xdress/scripts/xdress --debug -p=gccxml --builddir="/home/scopatz/xdress/tests/cppproj/build-gccxml"', '/home/scopatz/xdress/tests/cppproj', [1])
----------------------------------------------------------------------
Traceback (most recent call last):
File "/usr/lib/python2.7/dist-packages/nose/case.py", line 197, in runTest
self.test(*self.arg)
File "/home/scopatz/xdress/tests/tools.py", line 53, in check_cmd
assert_equal(rtn, 0)
scopatz@ares ~/cycamore/tests rwcarlsen-fix-crctx-again $ nosetests
/home/scopatz/.local/lib/python2.7/site-packages/tables/group.py:1156: UserWarning: problems loading leaf ``/InputFiles``::
table ``/InputFiles``, column ``Data``: variable length strings are not supported yet
The leaf will become an ``UnImplemented`` node.
% (self._g_join(childname), exc))
*** Error in `cyclus': free(): invalid pointer: 0x0000000001045e00 ***
======= Backtrace: =========
/lib/x86_64-linux-gnu/libc.so.6(+0x80996)[0x7fc2976ff996]