Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Problem(s) with multiple imports #59

Closed
oxtopus opened this issue Apr 4, 2015 · 3 comments
Closed

Problem(s) with multiple imports #59

oxtopus opened this issue Apr 4, 2015 · 3 comments

Comments

@oxtopus
Copy link

oxtopus commented Apr 4, 2015

Firstly, I'm on a mac.

I have two schemas. One imports and uses the other. When I import both schemas in Python, I get an error related to "Duplicate IDs", and in some cases, it crashes the python interpreter.

Importing individually is fine:

$ python -c 'from nupic.encoders.delta_capnp import DeltaEncoderProto'
$ python -c 'from nupic.encoders.adaptivescalar_capnp import AdaptiveScalarEncoderProto'

Importing them together raises a KjException related to duplicate IDs:

$ python -c 'from nupic.encoders.delta_capnp import DeltaEncoderProto;from nupic.encoders.adaptivescalar_capnp import AdaptiveScalarEncoderProto'
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "capnp/lib/capnp.pyx", line 3773, in capnp.lib.capnp._Loader.load_module (capnp/lib/capnp.cpp:71749)
  File "capnp/lib/capnp.pyx", line 3752, in capnp.lib.capnp.load (capnp/lib/capnp.cpp:71239)
  File "capnp/lib/capnp.pyx", line 3126, in capnp.lib.capnp.SchemaParser.load (capnp/lib/capnp.cpp:63334)
capnp.lib.capnp.KjException: /Users/amarshall/nta/nupic/nupic/encoders/adaptivescalar.capnp:0: failed: Duplicate ID @0xf11485b8c813b489.
stack: 0x10287bcdd 0x10287bd81 0x10270cfdb 0x10270dd84 0x1026e0566 0x1026de612 0x1026de237 0x1026de78d 0x1026e3f90 0x1026e4015 0x1026ed992 0x1026e5fef 0x1026e607d 0x1026e6a86 0x102706b35 0x102706a18

Then, if I change the import in delta.capnp to be relative, I get a segfault:

$ python -c 'from nupic.encoders.delta_capnp import DeltaEncoderProto;from nupic.encoders.adaptivescalar_capnp import AdaptiveScalarEncoderProto'
Segmentation fault: 11

For good measure, just to verify that I didn’t duplicate the ID:

$ cat nupic/encoders/delta.capnp nupic/encoders/adaptivescalar.capnp 
@0xdf5bd1fedf76298f;

using import "/nupic/encoders/adaptivescalar.capnp".AdaptiveScalarEncoderProto;

struct DeltaEncoderProto {
  width @0 :UInt32;
  name @1 :Text;
  n @2 :UInt32;
  adaptiveScalarEnc @3 :AdaptiveScalarEncoderProto;
  prevAbsolute @4 :Float32;
  prevDelta @5 :Float32;
  stateLock @6 :Bool;
}
@0xf11485b8c813b489;

using import "/nupic/movingaverage.capnp".MovingAverageProto;

# Next ID: 10
struct AdaptiveScalarEncoderProto {
  w @0 :UInt32;
  minval @1 :Float32;
  maxval @2 :Float32;
  periodic @3 :Bool;
  n @4 :UInt32;
  name @5 :Text;
  verbosity @6 :UInt8;
  clipInput @7 :Bool;
  recordNum @8 :UInt32;
  slidingWindow @9 :MovingAverageProto;
}
$ git grep f11485b8c813b489
nupic/encoders/adaptivescalar.capnp:@0xf11485b8c813b489;

It’s as if there’s a problem importing AdaptiveScalarEncoderProto a second time. Once implicitly in the delta.capnp schema and again explicitly in python.

I ran into a problem because a test I'm working on that imports both schemas was crashing my Python interpreter. For example, when I run numenta/nupic-legacy@e8ca7b5:

$ python tests/unit/nupic/encoders/scalarspace_test.py 
Segmentation fault: 11

With the crash reporter generating this message:

Process:               Python [8149]
Path:                  /System/Library/Frameworks/Python.framework/Versions/2.7/Resources/Python.app/Contents/MacOS/Python
Identifier:            Python
Version:               2.7.6 (2.7.6)
Code Type:             X86-64 (Native)
Parent Process:        bash [8128]
Responsible:           Terminal [400]
User ID:               502

PlugIn Path:             /Users/USER/Library/Python/2.7/lib/python/site-packages/pycapnp-0.5.1-py2.7-macosx-10.10-intel.egg/capnp/lib/capnp.so
PlugIn Identifier:       capnp.so
PlugIn Version:          ??? (0)

Date/Time:             2015-04-04 16:26:24.594 -0700
OS Version:            Mac OS X 10.10.2 (14C1514)
Report Version:        11
Anonymous UUID:        FF9C3939-A0B7-61F2-1A9B-6FCF211E857D

Sleep/Wake UUID:       FB51CEAD-3252-471E-A7E1-1347A8DD9267

Time Awake Since Boot: 520000 seconds
Time Since Wake:       1500 seconds

Crashed Thread:        0  Dispatch queue: com.apple.main-thread

Exception Type:        EXC_BAD_ACCESS (SIGSEGV)
Exception Codes:       EXC_I386_GPFLT

Thread 0 Crashed:: Dispatch queue: com.apple.main-thread
0   capnp.so                        0x0000000107a761a2 char* kj::_::fill<kj::ArrayPtr<char const>, kj::FixedArray<char, 1ul>, kj::ArrayPtr<char const> >(char*, kj::ArrayPtr<char const> const&, kj::FixedArray<char, 1ul>&&, kj::ArrayPtr<char const>&&) + 82
1   capnp.so                        0x0000000107a760db kj::String kj::_::concat<kj::ArrayPtr<char const>, kj::FixedArray<char, 1ul>, kj::ArrayPtr<char const> >(kj::ArrayPtr<char const>&&, kj::FixedArray<char, 1ul>&&, kj::ArrayPtr<char const>&&) + 219
2   capnp.so                        0x0000000107a75feb kj::String kj::str<kj::StringPtr&, char, kj::StringPtr&>(kj::StringPtr&&&, char&&, kj::StringPtr&&&) + 139
3   capnp.so                        0x0000000107a70b13 capnp::(anonymous namespace)::joinPath(kj::StringPtr, kj::StringPtr) + 211
4   capnp.so                        0x0000000107a74e0c capnp::SchemaFile::DiskSchemaFile::import(kj::StringPtr) const + 284
5   capnp.so                        0x0000000107a7687b capnp::SchemaParser::ModuleImpl::importRelative(kj::StringPtr) + 123
6   capnp.so                        0x0000000107a4c221 capnp::compiler::Compiler::CompiledModule::importRelative(kj::StringPtr) + 113
7   capnp.so                        0x0000000107a4c0e4 capnp::compiler::Compiler::Node::resolveImport(kj::StringPtr) + 84
8   capnp.so                        0x0000000107a11273 capnp::compiler::NodeTranslator::BrandScope::compileDeclExpression(capnp::compiler::Expression::Reader, capnp::compiler::NodeTranslator::Resolver&, capnp::compiler::NodeTranslator::ImplicitParams) + 2883
9   capnp.so                        0x0000000107a1203c capnp::compiler::NodeTranslator::BrandScope::compileDeclExpression(capnp::compiler::Expression::Reader, capnp::compiler::NodeTranslator::Resolver&, capnp::compiler::NodeTranslator::ImplicitParams) + 6412
10  capnp.so                        0x0000000107a1b18f capnp::compiler::NodeTranslator::compileDecl(unsigned long long, unsigned int, capnp::compiler::NodeTranslator::Resolver&, capnp::compiler::ErrorReporter&, capnp::compiler::Expression::Reader, capnp::schema::Brand::Builder) + 415
11  capnp.so                        0x0000000107a463ee capnp::compiler::Compiler::Alias::compile() + 606
12  capnp.so                        0x0000000107a4b5a2 capnp::compiler::Compiler::Node::resolveMember(kj::StringPtr) + 1746
13  capnp.so                        0x0000000107a4a712 capnp::compiler::Compiler::Node::resolve(kj::StringPtr) + 162
14  capnp.so                        0x0000000107a4aa74 capnp::compiler::Compiler::Node::resolve(kj::StringPtr) + 1028
15  capnp.so                        0x0000000107a10b5a capnp::compiler::NodeTranslator::BrandScope::compileDeclExpression(capnp::compiler::Expression::Reader, capnp::compiler::NodeTranslator::Resolver&, capnp::compiler::NodeTranslator::ImplicitParams) + 1066
16  capnp.so                        0x0000000107a18e04 capnp::compiler::NodeTranslator::compileDeclExpression(capnp::compiler::Expression::Reader, capnp::compiler::NodeTranslator::ImplicitParams) + 308
17  capnp.so                        0x0000000107a18832 capnp::compiler::NodeTranslator::compileType(capnp::compiler::Expression::Reader, capnp::schema::Type::Builder, capnp::compiler::NodeTranslator::ImplicitParams) + 338
18  capnp.so                        0x0000000107a30128 capnp::compiler::NodeTranslator::StructTranslator::translateInternal(capnp::compiler::NodeTranslator::StructTranslator::MemberInfo&, capnp::schema::Node::Builder) + 1464
19  capnp.so                        0x0000000107a29f51 capnp::compiler::NodeTranslator::StructTranslator::translate(capnp::Void, capnp::List<capnp::compiler::Declaration, (capnp::Kind)3>::Reader, capnp::schema::Node::Builder) + 321
20  capnp.so                        0x0000000107a15dff capnp::compiler::NodeTranslator::compileStruct(capnp::Void, capnp::List<capnp::compiler::Declaration, (capnp::Kind)3>::Reader, capnp::schema::Node::Builder) + 303
21  capnp.so                        0x0000000107a12e2b capnp::compiler::NodeTranslator::compileNode(capnp::compiler::Declaration::Reader, capnp::schema::Node::Builder) + 1371
22  capnp.so                        0x0000000107a127e6 capnp::compiler::NodeTranslator::NodeTranslator(capnp::compiler::NodeTranslator::Resolver&, capnp::compiler::ErrorReporter&, capnp::compiler::Declaration::Reader const&, capnp::Orphan<capnp::schema::Node>, bool) + 582
23  capnp.so                        0x0000000107a1312e capnp::compiler::NodeTranslator::NodeTranslator(capnp::compiler::NodeTranslator::Resolver&, capnp::compiler::ErrorReporter&, capnp::compiler::Declaration::Reader const&, capnp::Orphan<capnp::schema::Node>, bool) + 62
24  capnp.so                        0x0000000107a6513b void kj::ctor<capnp::compiler::NodeTranslator, capnp::compiler::Compiler::Node&, capnp::compiler::ErrorReporter&, capnp::compiler::Declaration::Reader&, capnp::Orphan<capnp::schema::Node>, bool>(capnp::compiler::NodeTranslator&, capnp::compiler::Compiler::Node&&&, capnp::compiler::ErrorReporter&&&, capnp::compiler::Declaration::Reader&&&, capnp::Orphan<capnp::schema::Node>&&, bool&&) + 251
25  capnp.so                        0x0000000107a52097 capnp::compiler::NodeTranslator& kj::Arena::allocate<capnp::compiler::NodeTranslator, capnp::compiler::Compiler::Node&, capnp::compiler::ErrorReporter&, capnp::compiler::Declaration::Reader&, capnp::Orphan<capnp::schema::Node>, bool>(capnp::compiler::Compiler::Node&&&, capnp::compiler::ErrorReporter&&&, capnp::compiler::Declaration::Reader&&&, capnp::Orphan<capnp::schema::Node>&&, bool&&) + 183
26  capnp.so                        0x0000000107a486db capnp::compiler::Compiler::Node::getContent(capnp::compiler::Compiler::Node::Content::State) + 4315
27  capnp.so                        0x0000000107a493d9 capnp::compiler::Compiler::Node::traverse(unsigned int, std::__1::unordered_map<capnp::compiler::Compiler::Node*, unsigned int, std::__1::hash<capnp::compiler::Compiler::Node*>, std::__1::equal_to<capnp::compiler::Compiler::Node*>, std::__1::allocator<std::__1::pair<capnp::compiler::Compiler::Node* const, unsigned int> > >&, capnp::SchemaLoader const&) + 121
28  capnp.so                        0x0000000107a4971b capnp::compiler::Compiler::Node::traverse(unsigned int, std::__1::unordered_map<capnp::compiler::Compiler::Node*, unsigned int, std::__1::hash<capnp::compiler::Compiler::Node*>, std::__1::equal_to<capnp::compiler::Compiler::Node*>, std::__1::allocator<std::__1::pair<capnp::compiler::Compiler::Node* const, unsigned int> > >&, capnp::SchemaLoader const&) + 955
29  capnp.so                        0x0000000107a4edc0 capnp::compiler::Compiler::Impl::eagerlyCompile(unsigned long long, unsigned int, capnp::SchemaLoader const&) + 672
30  capnp.so                        0x0000000107a4f3ae capnp::compiler::Compiler::eagerlyCompile(unsigned long long, unsigned int) const + 126
31  capnp.so                        0x0000000107a6f262 capnp::SchemaParser::parseFile(kj::Own<capnp::SchemaFile>&&) const + 226
32  capnp.so                        0x0000000107a6f0f8 capnp::SchemaParser::parseDiskFile(kj::StringPtr, kj::StringPtr, kj::ArrayPtr<kj::StringPtr const>) const + 168
33  capnp.so                        0x000000010791947c __pyx_f_5capnp_3lib_5capnp_12SchemaParser__parse_disk_file(__pyx_obj_5capnp_3lib_5capnp_SchemaParser*, _object*, _object*, _object*, int) + 1446
34  capnp.so                        0x000000010793ffca __pyx_pw_5capnp_3lib_5capnp_12SchemaParser_7load(_object*, _object*, _object*) + 2086
35  capnp.so                        0x000000010792ab3d __pyx_pw_5capnp_3lib_5capnp_27load(_object*, _object*, _object*) + 701
36  capnp.so                        0x0000000107929848 __pyx_pw_5capnp_3lib_5capnp_7_Loader_3load_module(_object*, _object*, _object*) + 1776
37  org.python.python               0x00000001074e12ac PyObject_Call + 99
38  org.python.python               0x00000001074ec0cf 0x1074d7000 + 86223
39  org.python.python               0x00000001074e12ac PyObject_Call + 99
40  org.python.python               0x00000001074e143d 0x1074d7000 + 42045
41  org.python.python               0x00000001074e164f PyObject_CallMethod + 253
42  org.python.python               0x0000000107572ed7 0x1074d7000 + 638679
43  org.python.python               0x0000000107572aa1 0x1074d7000 + 637601
44  org.python.python               0x0000000107570ce1 PyImport_ImportModuleLevel + 1191
45  org.python.python               0x00000001075563be 0x1074d7000 + 521150
46  org.python.python               0x00000001074e12ac PyObject_Call + 99
47  org.python.python               0x0000000107560d6b PyEval_CallObjectWithKeywords + 93
48  org.python.python               0x000000010755d071 PyEval_EvalFrameEx + 8411
49  org.python.python               0x000000010755ad62 PyEval_EvalCodeEx + 1413
50  org.python.python               0x000000010755a7d7 PyEval_EvalCode + 54
51  org.python.python               0x000000010757a7bd 0x1074d7000 + 669629
52  org.python.python               0x000000010757a860 PyRun_FileExFlags + 133
53  org.python.python               0x000000010757a3fd PyRun_SimpleFileExFlags + 769
54  org.python.python               0x000000010758bb23 Py_Main + 3051
55  libdyld.dylib                   0x00007fff83ec35c9 start + 1

Thread 0 crashed with X86 Thread State (64-bit):
  rax: 0xe3aa4f5dbdbea870  rbx: 0x000000010923c090  rcx: 0xe3aa4f5dbdbea871  rdx: 0x00007fff58726d20
  rdi: 0x00007fff58726d28  rsi: 0x00007fff58726d28  rbp: 0x00007fff58726c40  rsp: 0x00007fff58726c00
   r8: 0x0000000000000001   r9: 0x0000000000000001  r10: 0x0000000000000000  r11: 0x0000000000000246
  r12: 0x0000000109235b4c  r13: 0x000000010923c090  r14: 0x00007f9248d701c0  r15: 0x0000000000000024
  rip: 0x0000000107a761a2  rfl: 0x0000000000010286  cr2: 0x0000000210b3f829

Logical CPU:     6
Error Code:      0x00000000
Trap Number:     13


Binary Images:
       0x1074d0000 -        0x1074d0fff  org.python.python (2.7.6 - 2.7.6) <A7B51404-B996-3FDF-A40F-0CCE1837F1F4> /System/Library/Frameworks/Python.framework/Versions/2.7/Resources/Python.app/Contents/MacOS/Python
       0x1074d7000 -        0x1075c8ff7  org.python.python (2.7.6 - 2.7.6) <A5C1B694-31A0-3966-B6BC-C40694DC707F> /System/Library/Frameworks/Python.framework/Versions/2.7/Python
       0x1077cf000 -        0x1077d1fff  _collections.so (89) <4B0EB2CA-18E0-3F3A-B04B-94246814AF0F> /System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/lib-dynload/_collections.so
       0x1077d7000 -        0x1077dafff  operator.so (89) <049C4902-93FF-3453-BFEA-99F6461E63C1> /System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/lib-dynload/operator.so
       0x1077e0000 -        0x1077e4fff  itertools.so (89) <76FA3C45-95A0-3627-A5D9-F6E43D7FE09A> /System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/lib-dynload/itertools.so
       0x1077ed000 -        0x1077eefff  _heapq.so (89) <DC500847-4C9E-3782-9F26-388082125F57> /System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/lib-dynload/_heapq.so
       0x107833000 -        0x107834fff  _functools.so (89) <687C0F91-739D-3658-A815-C1CA87A0F4D3> /System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/lib-dynload/_functools.so
       0x107838000 -        0x107839fff  cStringIO.so (89) <A2B6CB97-BCA1-3D64-BFC0-F5F9ED139A2C> /System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/lib-dynload/cStringIO.so
       0x10783e000 -        0x10783ffff  time.so (89) <42DAC34B-013C-36E7-89A4-AE26FFBFD90E> /System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/lib-dynload/time.so
       0x107885000 -        0x107888ff7  math.so (89) <9B5C733C-9EEA-364B-B83E-E0D130F74CEA> /System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/lib-dynload/math.so
       0x1078ce000 -        0x107c74ff7 +capnp.so (0) <3F1DBD25-FB6E-3827-8E84-253B0890078A> /Users/USER/Library/Python/2.7/lib/python/site-packages/pycapnp-0.5.1-py2.7-macosx-10.10-intel.egg/capnp/lib/capnp.so
       0x1080b4000 -        0x1080b7fff  strop.so (89) <EF7B9ADA-CB8F-350F-87CB-413F1E8398D7> /System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/lib-dynload/strop.so
       0x1081bc000 -        0x1081c3ff7  _socket.so (89) <F7E0FFD6-78FC-3F79-A0D2-8AF7266FEB93> /System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/lib-dynload/_socket.so
       0x1081cd000 -        0x1081d0fff  _ssl.so (89) <67507A0A-090E-3201-86BE-BE72B4CDFB47> /System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/lib-dynload/_ssl.so
       0x1081d6000 -        0x10820cff7  libssl.0.9.8.dylib (52.10.1) <4A2D6ECA-A07E-38B5-98D4-315A4A1E8CE6> /usr/lib/libssl.0.9.8.dylib
       0x108262000 -        0x108264fff  binascii.so (89) <CB8E5D83-F54B-3570-8667-06B951C38DB0> /System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/lib-dynload/binascii.so
       0x108268000 -        0x108269fff  _hashlib.so (89) <706C58CB-4213-3845-B316-69D937257673> /System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/lib-dynload/_hashlib.so
       0x10826d000 -        0x10826eff7  _random.so (89) <0A7C79BC-D77F-3049-82B9-4ADF13CF1825> /System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/lib-dynload/_random.so
       0x108272000 -        0x1083b2fff +multiarray.so (???) <20692378-6291-39E7-AE94-C7F6776EFDA9> /Users/USER/Library/Python/2.7/lib/python/site-packages/numpy/core/multiarray.so
       0x10846b000 -        0x108474fff  datetime.so (89) <17581299-8DE2-3A9E-80A4-CF0F0A79CE13> /System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/lib-dynload/datetime.so
       0x10847d000 -        0x1084e1fff +umath.so (???) <FB05415F-AE90-38B1-B7C0-2BDAEA3F4F0C> /Users/USER/Library/Python/2.7/lib/python/site-packages/numpy/core/umath.so
       0x10854d000 -        0x108558fff  cPickle.so (89) <69D3AA38-D029-302C-8E8F-C8F2016C554B> /System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/lib-dynload/cPickle.so
       0x10855e000 -        0x108562ff7 +_dotblas.so (???) <F642F435-FA32-3AD0-933C-93E16CECF009> /Users/USER/Library/Python/2.7/lib/python/site-packages/numpy/core/_dotblas.so
       0x1085a6000 -        0x1085c7ff7 +scalarmath.so (???) <8589BCB6-86A8-32B7-941C-EE32E359E818> /Users/USER/Library/Python/2.7/lib/python/site-packages/numpy/core/scalarmath.so
       0x1085d9000 -        0x1085d9fff  grp.so (89) <DF55B2CB-E86C-3384-AB53-E183CE4B62A6> /System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/lib-dynload/grp.so
       0x1085dd000 -        0x1085ecfff  _io.so (89) <6FFCBD14-A18A-3F75-B926-CAFC02F58490> /System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/lib-dynload/_io.so
       0x1085fb000 -        0x1085fcfff  fcntl.so (89) <794692D1-C684-376C-AA4B-C1DBBD7C7A09> /System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/lib-dynload/fcntl.so
       0x108640000 -        0x108644fff +_compiled_base.so (???) <1C06B261-6E47-3F4E-81FF-F2C7052C90B3> /Users/USER/Library/Python/2.7/lib/python/site-packages/numpy/lib/_compiled_base.so
       0x108688000 -        0x108689fff +lapack_lite.so (???) <3F7FCFD2-43DC-3942-BE56-263A4C2B9865> /Users/USER/Library/Python/2.7/lib/python/site-packages/numpy/linalg/lapack_lite.so
       0x10868d000 -        0x1086a0fff +_umath_linalg.so (???) <3E71B5C5-776B-3B14-9065-562449F22D6C> /Users/USER/Library/Python/2.7/lib/python/site-packages/numpy/linalg/_umath_linalg.so
       0x1086ac000 -        0x1086acfff  future_builtins.so (89) <6F6B59EB-EBE9-30B6-9F03-9A1FC527D47C> /System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/lib-dynload/future_builtins.so
       0x1086b0000 -        0x1086b8fff +fftpack_lite.so (???) <80BF4739-CD32-3A75-9F6B-8E5122079FE5> /Users/USER/Library/Python/2.7/lib/python/site-packages/numpy/fft/fftpack_lite.so
       0x1086fc000 -        0x108753fff +mtrand.so (???) <1FF1E4EB-BBCE-351D-B724-297F0E82E5A7> /Users/USER/Library/Python/2.7/lib/python/site-packages/numpy/random/mtrand.so
       0x1087e8000 -        0x1087f6fff  _ctypes.so (89) <8BF6FB14-BF96-3CB3-BD44-39A5F402FF97> /System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/lib-dynload/_ctypes.so
       0x108801000 -        0x108804fff  _struct.so (89) <015BD869-7103-3735-A10A-70E4C15C9AB8> /System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/lib-dynload/_struct.so
       0x108943000 -        0x108e3dff7 +_math.so (0) <AC1CA188-2118-3DCF-9B42-2657543F9EC8> /Users/USER/*/_math.so
       0x109210000 -        0x109214fff  array.so (89) <80A6114A-394E-3817-BB38-677B513536CE> /System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/lib-dynload/array.so
       0x10925a000 -        0x109296ff7 +_proj.so (0) <F8DA2D50-CC1B-397F-8A0C-037AE7AA7496> /Users/USER/Library/Python/2.7/site-packages/pyproj/_proj.so
    0x7fff62b03000 -     0x7fff62b39837  dyld (353.2.1) <65DCCB06-339C-3E25-9702-600A28291D0E> /usr/lib/dyld
    0x7fff80671000 -     0x7fff80671ff7  libkeymgr.dylib (28) <77845842-DE70-3CC5-BD01-C3D14227CED5> /usr/lib/system/libkeymgr.dylib
    0x7fff80672000 -     0x7fff8067affb  libcopyfile.dylib (118.1.2) <0C68D3A6-ACDD-3EF3-991A-CC82C32AB836> /usr/lib/system/libcopyfile.dylib
    0x7fff8072a000 -     0x7fff80752fff  libsystem_info.dylib (459) <B85A85D5-8530-3A93-B0C3-4DEC41F79478> /usr/lib/system/libsystem_info.dylib
    0x7fff809ba000 -     0x7fff80a0efff  libc++.1.dylib (120) <1B9530FD-989B-3174-BB1C-BDC159501710> /usr/lib/libc++.1.dylib
    0x7fff80e5f000 -     0x7fff80ea5ff7  libauto.dylib (186) <A260789B-D4D8-316A-9490-254767B8A5F1> /usr/lib/libauto.dylib
    0x7fff80ea6000 -     0x7fff80ebcff7  libsystem_asl.dylib (267) <F153AC5B-0542-356E-88C8-20A62CA704E2> /usr/lib/system/libsystem_asl.dylib
    0x7fff80f58000 -     0x7fff80fe4ff7  libsystem_c.dylib (1044.10.1) <199ED5EB-77A1-3D43-AA51-81779CE0A742> /usr/lib/system/libsystem_c.dylib
    0x7fff810c3000 -     0x7fff810c4ffb  libremovefile.dylib (35) <3485B5F4-6CE8-3C62-8DFD-8736ED6E8531> /usr/lib/system/libremovefile.dylib
    0x7fff815ba000 -     0x7fff815e2fff  libxpc.dylib (559.10.3) <876216DC-D5D3-381E-8AF9-49AE464E5107> /usr/lib/system/libxpc.dylib
    0x7fff838f3000 -     0x7fff839a2fe7  libvMisc.dylib (516) <A82F9FE8-70ED-3BC9-9184-1A2B9EE3C010> /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libvMisc.dylib
    0x7fff83a7d000 -     0x7fff83a7fff7  libsystem_sandbox.dylib (358.1.1) <95312E09-DA28-324A-A084-F3E574D0210E> /usr/lib/system/libsystem_sandbox.dylib
    0x7fff83a8b000 -     0x7fff83a8bff7  libunc.dylib (29) <5676F7EA-C1DF-329F-B006-D2C3022B7D70> /usr/lib/system/libunc.dylib
    0x7fff83a98000 -     0x7fff83ac2ff7  libdispatch.dylib (442.1.4) <502CF32B-669B-3709-8862-08188225E4F0> /usr/lib/system/libdispatch.dylib
    0x7fff83ac3000 -     0x7fff83ac3fff  com.apple.Accelerate (1.10 - Accelerate 1.10) <2C8AF258-4F11-3BEC-A826-22D7199B3975> /System/Library/Frameworks/Accelerate.framework/Versions/A/Accelerate
    0x7fff83ec0000 -     0x7fff83ec3ff7  libdyld.dylib (353.2.1) <4E33E416-F1D8-3598-B8CC-6863E2ECD0E6> /usr/lib/system/libdyld.dylib
    0x7fff83ec4000 -     0x7fff83ec4ff7  liblaunch.dylib (559.10.3) <DFCDEBDF-8247-3DC7-9879-E7E497DDA4B4> /usr/lib/system/liblaunch.dylib
    0x7fff847f2000 -     0x7fff8480eff7  libsystem_malloc.dylib (53.1.1) <19BCC257-5717-3502-A71F-95D65AFA861B> /usr/lib/system/libsystem_malloc.dylib
    0x7fff84828000 -     0x7fff8493aff7  libvDSP.dylib (516) <151B3CCB-77D3-3715-A3D0-7C74CD5C7FFC> /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libvDSP.dylib
    0x7fff8493b000 -     0x7fff84ac9fff  libBLAS.dylib (1128) <497912C1-A98E-3281-BED7-E9C751552F61> /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libBLAS.dylib
    0x7fff8517c000 -     0x7fff8518dff3  libsystem_coretls.dylib (35.10.1) <3EAED90A-7AA0-323C-A52B-E16477981D59> /usr/lib/system/libsystem_coretls.dylib
    0x7fff8537c000 -     0x7fff853f2fe7  libcorecrypto.dylib (233.1.2) <E1789801-3985-3949-B736-6B3378873301> /usr/lib/system/libcorecrypto.dylib
    0x7fff854ff000 -     0x7fff85506ff7  libcompiler_rt.dylib (35) <BF8FC133-EE10-3DA6-9B90-92039E28678F> /usr/lib/system/libcompiler_rt.dylib
    0x7fff86cbe000 -     0x7fff86cc4fff  libsystem_trace.dylib (72.1.3) <A9E6B7D8-C327-3742-AC54-86C94218B1DF> /usr/lib/system/libsystem_trace.dylib
    0x7fff86cef000 -     0x7fff86cf0ff7  libsystem_blocks.dylib (65) <9615D10A-FCA7-3BE4-AA1A-1B195DACE1A1> /usr/lib/system/libsystem_blocks.dylib
    0x7fff877b5000 -     0x7fff877c0fff  libcommonCrypto.dylib (60061) <D381EBC6-69D8-31D3-8084-5A80A32CB748> /usr/lib/system/libcommonCrypto.dylib
    0x7fff877c1000 -     0x7fff877c6ff7  libmacho.dylib (862) <126CA2ED-DE91-308F-8881-B9DAEC3C63B6> /usr/lib/system/libmacho.dylib
    0x7fff877c7000 -     0x7fff877e4fff  libsystem_kernel.dylib (2782.10.72) <97CD7ACD-EA0C-3434-BEFC-FCD013D6BB73> /usr/lib/system/libsystem_kernel.dylib
    0x7fff87c6d000 -     0x7fff87e6746f  libobjc.A.dylib (647) <759E155D-BC42-3D4E-869B-6F57D477177C> /usr/lib/libobjc.A.dylib
    0x7fff88239000 -     0x7fff8823afff  libDiagnosticMessagesClient.dylib (100) <2EE8E436-5CDC-34C5-9959-5BA218D507FB> /usr/lib/libDiagnosticMessagesClient.dylib
    0x7fff8823c000 -     0x7fff8823cfff  com.apple.Accelerate.vecLib (3.10 - vecLib 3.10) <9D749502-A228-3BF1-B52F-A182DEEB2C4D> /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/vecLib
    0x7fff88594000 -     0x7fff8859cfff  libsystem_dnssd.dylib (561.1.1) <62B70ECA-E40D-3C63-896E-7F00EC386DDB> /usr/lib/system/libsystem_dnssd.dylib
    0x7fff885b6000 -     0x7fff885b8ff7  libsystem_coreservices.dylib (9) <41B7C578-5A53-31C8-A96F-C73E030B0938> /usr/lib/system/libsystem_coreservices.dylib
    0x7fff88716000 -     0x7fff887fafff  libcrypto.0.9.8.dylib (52.10.1) <2A2924DE-63FB-37F6-B102-84D69240675B> /usr/lib/libcrypto.0.9.8.dylib
    0x7fff88803000 -     0x7fff88814ff7  libz.1.dylib (55) <88C7C7DE-04B8-316F-8B74-ACD9F3DE1AA1> /usr/lib/libz.1.dylib
    0x7fff8899c000 -     0x7fff88d32fff  com.apple.CoreFoundation (6.9 - 1152) <CBD1591C-405E-376E-87E9-B264610EBF49> /System/Library/Frameworks/CoreFoundation.framework/Versions/A/CoreFoundation
    0x7fff88d98000 -     0x7fff890b3fcf  com.apple.vImage (8.0 - 8.0) <1183FE6A-FDB6-3B3B-928D-50C7909F2308> /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vImage.framework/Versions/A/vImage
    0x7fff89801000 -     0x7fff89806ff7  libsystem_stats.dylib (163.10.18) <9B8CCF24-DDDB-399A-9237-4BEC225D2E8C> /usr/lib/system/libsystem_stats.dylib
    0x7fff8a7da000 -     0x7fff8a9bfff3  libicucore.A.dylib (531.31) <B08E00D5-13C6-3391-AB3A-8DE693D3B42E> /usr/lib/libicucore.A.dylib
    0x7fff8a9e5000 -     0x7fff8a9e9fff  libcache.dylib (69) <45E9A2E7-99C4-36B2-BEE3-0C4E11614AD1> /usr/lib/system/libcache.dylib
    0x7fff8b4c1000 -     0x7fff8b4cafff  libsystem_pthread.dylib (105.10.1) <3103AA7F-3BAE-3673-9649-47FFD7E15C97> /usr/lib/system/libsystem_pthread.dylib
    0x7fff8c3e4000 -     0x7fff8c7f1ff7  libLAPACK.dylib (1128) <F9201AE7-B031-36DB-BCF8-971E994EF7C1> /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libLAPACK.dylib
    0x7fff8c7f2000 -     0x7fff8c81dfff  libc++abi.dylib (125) <88A22A0F-87C6-3002-BFBA-AC0F2808B8B9> /usr/lib/libc++abi.dylib
    0x7fff8c81e000 -     0x7fff8c81ffff  libsystem_secinit.dylib (18) <581DAD0F-6B63-3A48-B63B-917AF799ABAA> /usr/lib/system/libsystem_secinit.dylib
    0x7fff8c92a000 -     0x7fff8c92fff7  libunwind.dylib (35.3) <BE7E51A0-B6EA-3A54-9CCA-9D88F683A6D6> /usr/lib/system/libunwind.dylib
    0x7fff8cb0a000 -     0x7fff8cb12fff  libsystem_platform.dylib (63) <64E34079-D712-3D66-9CE2-418624A5C040> /usr/lib/system/libsystem_platform.dylib
    0x7fff8cb63000 -     0x7fff8cb9bffb  libsystem_network.dylib (411.1) <2EC3A005-473F-3C36-A665-F88B5BACC7F0> /usr/lib/system/libsystem_network.dylib
    0x7fff8ce49000 -     0x7fff8ce60ff7  libLinearAlgebra.dylib (1128) <E78CCBAA-A999-3B65-8EC9-06DB15E67C37> /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libLinearAlgebra.dylib
    0x7fff8d75d000 -     0x7fff8d75efff  libSystem.B.dylib (1213) <90B107BC-FF74-32CC-B1CF-4E02F544D957> /usr/lib/libSystem.B.dylib
    0x7fff8e3a4000 -     0x7fff8e3aaff7  libsystem_networkextension.dylib (167.1.10) <29AB225B-D7FB-30ED-9600-65D44B9A9442> /usr/lib/system/libsystem_networkextension.dylib
    0x7fff8e672000 -     0x7fff8e673fff  com.apple.TrustEvaluationAgent (2.0 - 25) <2D61A2C3-C83E-3A3F-8EC1-736DBEC250AB> /System/Library/PrivateFrameworks/TrustEvaluationAgent.framework/Versions/A/TrustEvaluationAgent
    0x7fff8e674000 -     0x7fff8e676ff7  libquarantine.dylib (76) <DC041627-2D92-361C-BABF-A869A5C72293> /usr/lib/system/libquarantine.dylib
    0x7fff8efd6000 -     0x7fff8efdfff7  libsystem_notify.dylib (133.1.1) <61147800-F320-3DAA-850C-BADF33855F29> /usr/lib/system/libsystem_notify.dylib
    0x7fff8f422000 -     0x7fff8f424fff  libsystem_configuration.dylib (699.1.5) <5E14864E-089A-3D84-85A4-980B776427A8> /usr/lib/system/libsystem_configuration.dylib
    0x7fff8f709000 -     0x7fff8f70afff  libffi.dylib (18.1) <0F6C6A4D-1210-3585-8DA1-B8A94B9924A5> /usr/lib/libffi.dylib
    0x7fff8fca8000 -     0x7fff8fcd8fff  libsystem_m.dylib (3086.1) <1E12AB45-6D96-36D0-A226-F24D9FB0D9D6> /usr/lib/system/libsystem_m.dylib

External Modification Summary:
  Calls made by other processes targeting this process:
    task_for_pid: 0
    thread_create: 0
    thread_set_state: 0
  Calls made by this process:
    task_for_pid: 0
    thread_create: 0
    thread_set_state: 0
  Calls made by all processes on this machine:
    task_for_pid: 314641
    thread_create: 0
    thread_set_state: 0

VM Region Summary:
ReadOnly portion of Libraries: Total=114.9M resident=84.6M(74%) swapped_out_or_unallocated=30.3M(26%)
Writable regions: Total=4.2G written=11.1M(0%) resident=14.6M(0%) swapped_out=0K(0%) unallocated=4.2G(100%)

REGION TYPE                      VIRTUAL
===========                      =======
Kernel Alloc Once                     4K
MALLOC                            175.3M
MALLOC (admin)                       16K
MALLOC_LARGE (reserved)             4.0G        reserved VM address space (unallocated)
STACK GUARD                        56.0M
Stack                              8192K
VM_ALLOCATE                          16K
__DATA                             2640K
__LINKEDIT                         79.3M
__TEXT                             35.6M
__UNICODE                           544K
shared memory                         4K
===========                      =======
TOTAL                               4.3G
TOTAL, minus reserved VM space    357.4M
oxtopus added a commit to oxtopus/nupic that referenced this issue Apr 6, 2015
@jparyani
Copy link
Contributor

jparyani commented Apr 8, 2015

Hmm, I'm having a lot of trouble reproducing (specifically I'm getting a Fatal Python error: PyThreadState_Get: no current thread whenever I try to import nupic on my OSX box). That being said, I'm pretty sure I fixed this bug in the 0.5.4 release (see https://github.com/jparyani/pycapnp/blob/develop/CHANGELOG.md#v054-2015-03-02). Can you try that out and let me know if it works for you?

@oxtopus
Copy link
Author

oxtopus commented Apr 8, 2015

Will do. Thanks!

I tried to craft a simpler scenario, but wasn't able to reproduce. FWIW, if you look at the history of numenta/nupic-legacy#2007, the failing Travis builds were related to the same failure (the python interpreter crashed). The crashes stopped and it all started working when I switched to relative imports.

Thanks for trying it out!

@oxtopus
Copy link
Author

oxtopus commented Apr 8, 2015

Upgrading to 0.5.4 did the trick. Thanks!

@oxtopus oxtopus closed this as completed Apr 8, 2015
mihail911 pushed a commit to mihail911/nupic that referenced this issue Aug 5, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants