Skip to content

Copy all eventspace counters to host efficiently at each time step #282

@denisalevi

Description

@denisalevi

Currently, there are multiple kernels that require or could be optimized when having the number of spiking neurons on the host and each kernel calls their own cudaMemcpy or would have to.

Instead, implement an asynchronous cudaMemcpy from device to host after all thresholders (for any spike or event condition) are run.

  1. Move the event counters for all eventspaces into a single contiguous array, such that one copy can copy all counters for multiple eventspaces at once. This would require changing the access to the counter variable in some kernels, but should be easy to do.
  2. Detect from Python side which kernel will be the first to require the counter variables. That kernel should that synchronize with the asynchronous copy call. Also detect if no kernel requires the counters and don't copy in that case.

Related issues that would benefit or could be closed by this:

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions