Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/master' into qa/clean-up-load-ba…
Browse files Browse the repository at this point in the history
…lance
  • Loading branch information
thorstenhater committed Sep 12, 2023
2 parents 89aa985 + 90c3948 commit 0aab605
Show file tree
Hide file tree
Showing 38 changed files with 380 additions and 610 deletions.
48 changes: 44 additions & 4 deletions .github/workflows/sanitize.yml
Original file line number Diff line number Diff line change
@@ -1,10 +1,18 @@
name: Sanitize

on:
pull_request:
push:
branches: [ master ]
paths-ignore: 'doc/**'

schedule:
- cron: '0 2 * * 0' # run at 2 AM every sunday

permissions:
issues: write
pull-requests: write
contents: write

jobs:
build:
name: "Sanitize"
Expand Down Expand Up @@ -58,7 +66,39 @@ jobs:
cd -
- name: Run unit tests
run: |
build/bin/unit --gtest_filter=-*DeathTest
build/bin/unit-modcc
build/bin/unit --gtest_filter=-*DeathTest 2>&1 | tee output.log
build/bin/unit-modcc 2>&1 | tee -a output.log
shell: bash
- name: Run examples
run: scripts/run_cpp_examples.sh
run: scripts/run_cpp_examples.sh 2>&1 | tee -a output.log
shell: bash
- name: Ouput File
if: ${{ failure() && github.event_name == 'schedule' }}
run: |
FENCE='```'
HEADER="$(cat << EOF
<details>
<summary>output from test runs</summary>
${FENCE}
EOF
)"
FOOTER="$(cat << EOF
${FENCE}
</details>
EOF
)"
echo "${HEADER}" > issue.md
cat output.log >> issue.md
echo "${FOOTER}" >> issue.md
echo -e "\nSee also the [corresponding workflow](${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }})\n" >> issue.md
- name: Create Issue From File
if: ${{ failure() && github.event_name == 'schedule' }}
uses: peter-evans/create-issue-from-file@v4
with:
title: '[AUTOMATED] Sanitize checks failed'
content-filepath: ./issue.md
labels: |
automated issue
2 changes: 1 addition & 1 deletion .github/workflows/test-docs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
strategy:
matrix:
os: [ubuntu-20.04]
python-version: [3.7]
python-version: [3.8]
steps:
- name: Set up cmake
uses: jwlawson/[email protected]
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/test-matrix.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
os: "ubuntu-20.04",
cc: "gcc-9",
cxx: "g++-9",
py: "3.7",
py: "3.8",
cmake: "3.19.x",
mpi: "ON",
simd: "OFF"
Expand All @@ -30,7 +30,7 @@ jobs:
os: "ubuntu-20.04",
cc: "clang-9",
cxx: "clang++-9",
py: "3.7",
py: "3.8",
cmake: "3.19.x",
mpi: "ON",
simd: "OFF"
Expand All @@ -40,7 +40,7 @@ jobs:
os: "macos-11",
cc: "clang",
cxx: "clang++",
py: "3.7",
py: "3.8",
cmake: "3.19.x",
mpi: "ON",
simd: "OFF"
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/test-pip.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
strategy:
matrix:
os: [ubuntu-20.04]
python-version: [3.7]
python-version: [3.8]
steps:
- uses: actions/setup-python@v4
with:
Expand Down
7 changes: 3 additions & 4 deletions .readthedocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,10 @@ sphinx:
formats: []

build:
os: ubuntu-20.04
os: ubuntu-22.04
tools:
python: "3.7"
python: "3.11"

python:
system_packages: true
install:
- requirements: doc/requirements.txt
- requirements: doc/requirements.txt
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ After much more delay than anticipated, we are very happy to present a new Arbor
## New Contributors
* @musicinmybrain made their first contribution in https://github.com/arbor-sim/arbor/pull/2080

**Full Changelog**: https://github.com/arbor-sim/arbor/compare/v0.8...v0.9.0-rc
**Full Changelog**: https://github.com/arbor-sim/arbor/compare/v0.8.1...v0.9.0


# v0.8.1
Expand Down
14 changes: 7 additions & 7 deletions CITATION.bib
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ @INPROCEEDINGS{
doi={10.1109/EMPDP.2019.8671560},
ISSN={2377-5750}}
@software{nora_abi_akar_2022_7473671,
@software{nora_abi_akar_2023_8233847,
author = {Nora Abi Akar and
John Biddiscombe and
Benjamin Cumming and
Expand All @@ -32,11 +32,11 @@ @software{nora_abi_akar_2022_7473671
Simon Frasch and
Lukas Drescher and
Lennart Landsmeer},
title = {Arbor Library v0.8.1},
title = {Arbor Library v0.9.0},
month = nov,
year = 2022,
year = 2023,
publisher = {Zenodo},
version = {v0.8},
doi = {10.5281/zenodo.7473671},
url = {https://doi.org/10.5281/zenodo.7473671}
}
version = {v0.9.0},
doi = {10.5281/zenodo.8233847},
url = {https://doi.org/10.5281/zenodo.8233847}
}
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -359,7 +359,7 @@ endif()
#----------------------------------------------------------

# The minimum version of Python supported by Arbor.
set(arb_py_version 3.7.0)
set(arb_py_version 3.8.0)

if(DEFINED PYTHON_EXECUTABLE)
set(Python3_EXECUTABLE ${PYTHON_EXECUTABLE})
Expand Down
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.9.0
0.9.1-dev
2 changes: 1 addition & 1 deletion arbor/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ set(arbor_sources
io/serialize_hex.cpp
label_resolution.cpp
lif_cell_group.cpp
mc_cell_group.cpp
cable_cell_group.cpp
mechcat.cpp
mechinfo.cpp
memory/gpu_wrappers.cpp
Expand Down
2 changes: 1 addition & 1 deletion arbor/backends/event_delivery.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ Target handles are used by the lowered cell implementation to identify a particu
instance that can receive events — ultimately via `net_receive` — and corresponding simulated
cell. The cell information is given as an index into the cell group collection of cells.

Target handles are represented by the `target_handle` struct, opaque to `mc_cell_group`,
Target handles are represented by the `target_handle` struct, opaque to `cable_cell_group`,
but created in the `fvm_multicell` for each point mechanism (synapse) in the cell group.

### Deliverable events
Expand Down
20 changes: 10 additions & 10 deletions arbor/mc_cell_group.cpp → arbor/cable_cell_group.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
#include "cell_group.hpp"
#include "fvm_lowered_cell.hpp"
#include "label_resolution.hpp"
#include "mc_cell_group.hpp"
#include "cable_cell_group.hpp"
#include "profile/profiler_macro.hpp"
#include "sampler_map.hpp"
#include "util/filter.hpp"
Expand All @@ -26,7 +26,7 @@

namespace arb {

mc_cell_group::mc_cell_group(const std::vector<cell_gid_type>& gids,
cable_cell_group::cable_cell_group(const std::vector<cell_gid_type>& gids,
const recipe& rec,
cell_label_range& cg_sources,
cell_label_range& cg_targets,
Expand Down Expand Up @@ -68,7 +68,7 @@ mc_cell_group::mc_cell_group(const std::vector<cell_gid_type>& gids,
spike_sources_.shrink_to_fit();
}

void mc_cell_group::reset() {
void cable_cell_group::reset() {
spikes_.clear();

for (auto &entry: sampler_map_) {
Expand All @@ -92,9 +92,9 @@ struct sampler_call_info {
sample_size_type end_offset;
};

void mc_cell_group::t_serialize(serializer& ser,
void cable_cell_group::t_serialize(serializer& ser,
const std::string& k) const { serialize(ser, k, *this); }
void mc_cell_group::t_deserialize(serializer& ser,
void cable_cell_group::t_deserialize(serializer& ser,
const std::string& k) { deserialize(ser, k, *this); }

// Working space for computing and collating data for samplers.
Expand Down Expand Up @@ -382,7 +382,7 @@ void run_samples(
std::visit([&](auto& x) {run_samples(x, sc, raw_times, raw_samples, sample_records, scratch); }, sc.pdata_ptr->info);
}

void mc_cell_group::advance(epoch ep, time_type dt, const event_lane_subrange& event_lanes) {
void cable_cell_group::advance(epoch ep, time_type dt, const event_lane_subrange& event_lanes) {
time_type tstart = lowered_->time();

// Bin and collate deliverable events from event lanes.
Expand Down Expand Up @@ -510,7 +510,7 @@ void mc_cell_group::advance(epoch ep, time_type dt, const event_lane_subrange& e
}
}

void mc_cell_group::add_sampler(sampler_association_handle h, cell_member_predicate probeset_ids,
void cable_cell_group::add_sampler(sampler_association_handle h, cell_member_predicate probeset_ids,
schedule sched, sampler_function fn)
{
std::lock_guard<std::mutex> guard(sampler_mex_);
Expand All @@ -524,17 +524,17 @@ void mc_cell_group::add_sampler(sampler_association_handle h, cell_member_predic
}
}

void mc_cell_group::remove_sampler(sampler_association_handle h) {
void cable_cell_group::remove_sampler(sampler_association_handle h) {
std::lock_guard<std::mutex> guard(sampler_mex_);
sampler_map_.erase(h);
}

void mc_cell_group::remove_all_samplers() {
void cable_cell_group::remove_all_samplers() {
std::lock_guard<std::mutex> guard(sampler_mex_);
sampler_map_.clear();
}

std::vector<probe_metadata> mc_cell_group::get_probe_metadata(cell_member_type probeset_id) const {
std::vector<probe_metadata> cable_cell_group::get_probe_metadata(cell_member_type probeset_id) const {
// Probe associations are fixed after construction, so we do not need to grab the mutex.

std::optional<probe_tag> maybe_tag = util::value_by_key(probe_map_.tag, probeset_id);
Expand Down
8 changes: 4 additions & 4 deletions arbor/mc_cell_group.hpp → arbor/cable_cell_group.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,11 @@

namespace arb {

class ARB_ARBOR_API mc_cell_group: public cell_group {
class ARB_ARBOR_API cable_cell_group: public cell_group {
public:
mc_cell_group() = default;
cable_cell_group() = default;

mc_cell_group(const std::vector<cell_gid_type>& gids,
cable_cell_group(const std::vector<cell_gid_type>& gids,
const recipe& rec,
cell_label_range& cg_sources,
cell_label_range& cg_targets,
Expand Down Expand Up @@ -57,7 +57,7 @@ class ARB_ARBOR_API mc_cell_group: public cell_group {

std::vector<probe_metadata> get_probe_metadata(cell_member_type probeset_id) const override;

ARB_SERDES_ENABLE(mc_cell_group, gids_, spikes_, lowered_);
ARB_SERDES_ENABLE(cable_cell_group, gids_, spikes_, lowered_);

virtual void t_serialize(serializer& ser, const std::string& k) const override;
virtual void t_deserialize(serializer& ser, const std::string& k) override;
Expand Down
4 changes: 2 additions & 2 deletions arbor/cell_group_factory.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
#include "execution_context.hpp"
#include "fvm_lowered_cell.hpp"
#include "lif_cell_group.hpp"
#include "mc_cell_group.hpp"
#include "cable_cell_group.hpp"
#include "spike_source_cell_group.hpp"

namespace arb {
Expand All @@ -27,7 +27,7 @@ ARB_ARBOR_API cell_group_factory cell_kind_implementation(
switch (ck) {
case cell_kind::cable:
return [bk, ctx, seed](const gid_vector& gids, const recipe& rec, cell_label_range& cg_sources, cell_label_range& cg_targets) {
return make_cell_group<mc_cell_group>(gids, rec, cg_sources, cg_targets, make_fvm_lowered_cell(bk, ctx, seed));
return make_cell_group<cable_cell_group>(gids, rec, cg_sources, cg_targets, make_fvm_lowered_cell(bk, ctx, seed));
};

case cell_kind::spike_source:
Expand Down
2 changes: 1 addition & 1 deletion arbor/fvm_lowered_cell.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@ struct fvm_probe_data {
};

// Samplers are tied to probe ids, but one probe id may
// map to multiple probe representations within the mc_cell_group.
// map to multiple probe representations within the cable_cell_group.

struct probe_association_map {
// Keys are probe id.
Expand Down
2 changes: 1 addition & 1 deletion doc/concepts/decor.rst
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@ Take for example the built-in mechanism for passive leaky dynamics:
.. _cablecell-scaled-mechs:

4. Scaling Mechanism and Membrane Parameters
~~~~~~~~~~~~~~~~~~~~~
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Mechanism parameters are usually homogeneous along a cell. However, sometimes it
is useful to scale parameters based on inhomogeneous properties.
Expand Down
Loading

0 comments on commit 0aab605

Please sign in to comment.