T owards parallelizing the Gillespie SSA Srivastav Ranganathan - - PowerPoint PPT Presentation

t owards parallelizing the gillespie ssa
SMART_READER_LITE
LIVE PREVIEW

T owards parallelizing the Gillespie SSA Srivastav Ranganathan - - PowerPoint PPT Presentation

T owards parallelizing the Gillespie SSA Srivastav Ranganathan and Aparna JS Indian Institute of Technology Bombay Mumbai, India Gillespie Algorithm A stochastic simulation approach to study the time evolution of a system of reactions


slide-1
SLIDE 1

T

  • wards parallelizing the

Gillespie SSA

Srivastav Ranganathan and Aparna JS Indian Institute of Technology Bombay Mumbai, India

slide-2
SLIDE 2

Gillespie Algorithm

  • A stochastic simulation approach to study the time

evolution of a system of reactions (processes)

  • Each reaction occurs at an average rate
  • The abundance of various species and their rates decide

the propensity of each event to occur

  • Many independent trajectories are generated to compute

ensemble averaged statistical quantities

slide-3
SLIDE 3

Where is it used?

  • In biological systems
  • Outcomes of cellular processes are driven by

stochasticity at a molecular level

  • Deterministic approaches cannot capture the inherent

randomness of biological systems

slide-4
SLIDE 4

The algorithm

slide-5
SLIDE 5

Initialize the system (individual rates)

Compute the probabilities of going from one state to another (pi)

Generate the fjring time for the next reaction to be fjred Select the next reaction to be fjred

Most expensive of all these steps

slide-6
SLIDE 6

Selecting the event to be fjred

  • Draw a uniform random number ran1

P1

P1+ P2 P1+P2 ….P8 P1+P2+.. +P4 P1+ P2.. P3

Fire Reaction 1 Fire Reaction 4

  • Update the system confjguration based on the fjred reaction (abundance, rates etc)
  • Update the time based on the exponential distribution of wait time between events (
slide-7
SLIDE 7

This search for the next event to be fjred is really expensive if there is a large reaction space!

slide-8
SLIDE 8
slide-9
SLIDE 9
slide-10
SLIDE 10

Our attempt (Scheme 1, One-One communications)

Master

  • Owns the transition

probability matrix

  • Keeps the system

confjg updated W1 W2 W3 Worker Nodes: Receive blocks of the search space Identify the event to be fjred Pass the event info into a bufger, if a hit is received MPI_REDUCE (MPI_MAX) MPI_SEND MPI_SEND MPI_SEND

slide-11
SLIDE 11
slide-12
SLIDE 12

Our attempt (Scheme 2, Collective communication)

Master

  • Owns the transition

probability matrix

  • Also performs part
  • f the search
  • Keeps the system

confjg updated W1 W2 W3

Worker Nodes: Receive blocks of the search space Identify the event to be fjred Pass the event info into a bufger, if a hit is received

MPI_REDUCE (MPI_MAX) MPI_SCATTER MPI_SCATTER MPI_SCATTER

slide-13
SLIDE 13
slide-14
SLIDE 14
  • Our naïve serial code was optimized to minimize cache

misses (a speedup of 1.5 times)

  • The MPI code did give us correct results (compared

with the serial code and analytical results!)

  • Exposed us to a new way of thinking

What worked

slide-15
SLIDE 15
  • MPI codes show a speedup from 1 to 3 cores but scale

poorly

  • Performance slows down at 5 processes or more
  • Probably due to huge communication overhead in our

code

  • Possibly revisit the whole algorithm or use a more

parallel-friendly algorithm!

What did`nt?

slide-16
SLIDE 16

Thank You!