Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

View waTeim's full-sized avatar

Jeff Waller waTeim

View GitHub Profile
@waTeim
waTeim / Just node by itself
Created October 30, 2014 21:15
gdb output following seg-fault while running node-julia on a simple input file node libuv = 1.0.x julia libuv = 0.11.x
Reading symbols from /usr/local/bin/node...done.
(gdb) info files
Symbols from "/usr/local/bin/node".
Local exec file:
`/usr/local/bin/node', file type elf64-x86-64.
Entry point: 0x5fd9e0
0x0000000000400200 - 0x000000000040021c is .interp
0x000000000040021c - 0x000000000040023c is .note.ABI-tag
0x0000000000400240 - 0x0000000000426db4 is .hash
0x0000000000426db8 - 0x00000000004aefb8 is .dynsym
const solMass = 4 * pi^2
const daysPYear = 365.24
immutable ThreeD
x::Float64
y::Float64
z::Float64
end
# all these functions modify a global array, a better idea is to pass them the array
@waTeim
waTeim / gist:4118fe8c6e96e14728bf
Last active August 29, 2015 14:10
Try/catch vs NaN
function t1(x::Float64)
if x == 100_000_000 throw(DomainError()); end
return x;
end
function t2(x::Float64)
if x == 100_000_000
return NaN;
else
return x;
@waTeim
waTeim / PGPP-stage2.cpp
Created March 2, 2015 21:15
Typedef traversal assert failure
#include <iostream>
#include "clang/Frontend/FrontendActions.h"
#include "clang/Tooling/CommonOptionsParser.h"
#include "clang/Tooling/Tooling.h"
#include "llvm/Support/CommandLine.h"
#include "clang/ASTMatchers/ASTMatchers.h"
#include "clang/ASTMatchers/ASTMatchFinder.h"
using namespace std;
using namespace clang;
@waTeim
waTeim / DumpBinOutput.txt
Created May 18, 2015 04:49
Embedding Julia with gyp for node-julia attempt
Microsoft (R) COFF/PE Dumper Version 12.00.31101.0
Copyright (C) Microsoft Corporation. All rights reserved.
Dump of file C:\Julia\julia-f875a541be\bin\libjulia.dll
File Type: DLL
Section contains the following exports for libjulia.dll
@waTeim
waTeim / JuliaMakeInstall.txt
Created May 20, 2015 07:36
Output of Julia make install
bizarro% make install
CC usr/bin/stringreplace
. /Users/jeffw/src/julia/deps/julia-env/bin/activate && sphinx-build -b html -d _build/doctrees . _build/html
Making output directory...
Running Sphinx v1.2.3
loading pickled environment... not yet created
building [html]: targets for 74 source files that are out of date
updating environment: 74 added, 0 changed, 0 removed
reading sources... [100%] stdlib/test
/Users/jeffw/src/julia/doc/stdlib/collections.rst:121: WARNING: duplicate object description of Base.length, other instance in /Users/jeffw/src/julia/doc/stdlib/arrays.rst, use :noindex: for one of them
@waTeim
waTeim / test
Created June 29, 2015 03:16
Oracle Java execution in Julia
jeffw@ub0:~/src/JavaCall.jl/src$ julia test.jl
Loaded /usr/lib/jvm/java-7-oracle/jre/lib/amd64/server/libjvm.so
[Dynamic-linking native method java.lang.Object.registerNatives ... JNI]
[Registering JNI native method java.lang.Object.hashCode]
[Registering JNI native method java.lang.Object.wait]
[Registering JNI native method java.lang.Object.notify]
[Registering JNI native method java.lang.Object.notifyAll]
[Registering JNI native method java.lang.Object.clone]
[Dynamic-linking native method java.lang.System.registerNatives ... JNI]
[Registering JNI native method java.lang.System.currentTimeMillis]
@waTeim
waTeim / JavaCall master
Last active August 29, 2015 14:23
Oracle JVM with signal handlers disabled
julia> jcall(jlm, "Sin", jdouble, (jdouble,), pi/2)
WARNING: gc_disable() is deprecated, use gc_enable(false) instead.
in depwarn at ./deprecated.jl:62
in gc_disable at deprecated.jl:49
in jcall at /home/jeffw/.julia/v0.4/JavaCall/src/JavaCall.jl:254
while loading no file, in expression starting on line 0
[Dynamic-linking native method java.lang.ClassLoader.findLoadedClass0 ... JNI]
[Dynamic-linking native method java.lang.ClassLoader.findBootstrapClass ... JNI]
#
# A fatal error has been detected by the Java Runtime Environment:
@waTeim
waTeim / Windows Crash 2
Last active August 29, 2015 14:24
Output of npm test on windows using sys.ji
child_process: customFds option is deprecated, use stdio instead.
Please submit a bug report with steps to reproduce this fault, and any error messages that follow (in their entirety). Thanks.
Exception: EXCEPTION_ACCESS_VIOLATION at 0x771510e2 -- RtlAnsiStringToUnicodeString at C:\Windows\SYSTEM32\ntdll.dll (unknown line)
RtlAnsiStringToUnicodeString at C:\Windows\SYSTEM32\ntdll.dll (unknown line)
HeapFree at C:\Windows\system32\kernel32.dll (unknown line)
v8::Unlocker::~Unlocker at C:\Program Files\nodejs\node.exe (unknown line)
getipaddr at socket.jl:632
init_bind_addr at client.jl:203
init_parallel at client.jl:375
@waTeim
waTeim / GoogleNetviaProtoBufJL.txt
Created July 14, 2015 05:26
GoogleNet via ProtoBuf.jl
julia> f = open("bvlc_googlenet.caffemodel")
IOStream(<file bvlc_googlenet.caffemodel>)
julia> include("generated/caffe.jl")
caffe
julia> x = ProtoBuf.readproto(f,caffe.NtParameter())
ERROR: UndefVarError: NtParameter not defined
julia> x = ProtoBuf.readproto(f,caffe.NetParameter())