- Sep 22, 2020
-
-
Benjamin Cumming authored
* Move label and s-expr parsing code and unit tests from Python to arbor C++ library. * Update `locset` and `region` constructors that take string arguments to parse strings as s-expressions or "quoted" labels. * Modify the input stream modifier used to parse asc files to use a lookup table for substitutions, renamed it transmogrifier. * Replace `hopefully` type implemented in python headers with an `arb::util::expected`. * Add `ARBDEV_COLOR` CMake option that forces gcc and clang to always output color output. * Allow arbitrary strings in labels in region and locset expressions. * Add `parse_region_expression` and `parse_locset_expression` functions alongside the existing `parse_label_expression` function for use when a region or locset is expected. These calls will promote a quoted string `"label"` to `(region "label")` or `(locset "label")` respectively. * Add user-defined string literals for labels so that the C++ interface can use `"soma"_lab` instead of awkward escaping `"\"soma\""`. * Simplify Python wrapper code.
-
- Sep 14, 2020
-
-
Sam Yates authored
* Implement a workalike for the proposed `std::expected` class: see http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2019/p0323r9.html . * Replace use of `either` with `expected` in `mprovider`, `mechanism_catalogue`, `util::partition_range`, and `pyarb::hopefully`. * Replace use of `either` with `variant` in `util::sentinel_iterator`. * Add `in_place_t` constructor for `util::optional`. * Fix move assignment bug in `util::variant`. * Remove `util/either.hpp` and associated tests. Fixes #1135.
-
- Feb 04, 2020
-
-
Benjamin Cumming authored
A big update that wraps over 90% of the public C++ API, with enough functionality to let Python users to perform useful modelling. Key features - wrapping of cable cell functionality - user-defined explicit compartmentalisation not supported - `single_cell_model` abstraction unique to the Python wrapper that simplifies developing and testing single cell models - one-dimensional cell builder for Python wrapper that simplfies building cells that - in and of itself limited in scope, but a very useful example of mapping a richer morphology builder onto `sample_tree`s. - parsing of region and location expressions from strings - implements a generic s-expression parser that we can use for other purposes later
-
- Oct 02, 2019
-
-
Ensure that errors in Python callbacks that are called from multithreaded C++ code propogate the correct Python error back to the parent Python callback site, and that no callbacks are called from other threads if an error has already ocurred. - protects each recipe callback with a mutex, stores python exception, catches and throws python exception if occured - methods calling recipe (in simulation and partition_load_balance) are protected as well by try catch, resets and rethrows python exception (if occured) or else throws C++ exception fixes #792
-
- Jun 05, 2019
-
-
Benjamin Cumming authored
-
- May 09, 2019
-
-
Wrapped the following C++ features in Python: - Identifiers (`cell_member`) + according tests - `event_generator` and schedules (`regular_schedule`, `explicit_schedule`, `poisson_schedule`) + according tests
-