taichi: Some examples fail on macOS

They all seem to fail with the same assertion:

$ python bubbles.py
asset_manager.h@(Ln 20): Assertion Failed. [Asset has been expired]

My taichi is compiled against Python 2.7.13, boost 1.6.13, embree 2.13.0, and tbb 4.4-20161128.

The examples that do work are:

  • geometry
  • scoping
  • trees

About this issue

  • Original URL
  • State: closed
  • Created 7 years ago
  • Reactions: 1
  • Comments: 27 (22 by maintainers)

Commits related to this issue

Most upvoted comments

It’s indeed a strange problem…Maybe a good way to debug, is to add some debug output in the destructor of taichi::Texture in C++, so that we can know when it’s destroyed (and the weak_ptr expires). I’ll deal with it later. Sorry to get you so involved in this issue.

Because we know that the weak_ptr prematurely expiring is the issue I was able to make some progress in running the examples by storing a shared_ptr in AssetManager instead… Wish I could be more helpful but I’m new to C++11 and boost.python 😃

It’s strange that textures do not work. I’ll probably deal with it after work today, thanks.