[kepler-users] Linda type models

Christopher Brooks cxh at eecs.berkeley.edu
Fri Jul 20 09:10:36 PDT 2012


Ptolemy II does not have a specific Linda model of computation, but 
there are a number of resources for coordination languages.

Edward Lee's IEEE Computer article "The Problem with Threads" provides a 
good overview of the Ptolemy II's view of coordination languages
http://ptolemy.eecs.berkeley.edu/publications/papers/06/problemwithThreads/

Edward and I developed a talk a while back that talks more about 
coordination languages and Ptolemy II.
http://chess.eecs.berkeley.edu/pubs/164

Try searching the CHESS website for coordination languages.  With 
Google, I did
  coordination language site:chess.eecs.berkeley.edu

More specifically, we started work on  Synchronous Publisher Subscriber 
model of
computation that was implemented via 
ptolemy/domains/sps/kernel/SPSDirector.java

The class comment for that file was:
> The Synchronous Publisher Subscriber (SPS) model of computation.
> <p>
>    In this model of computation input and output ports have channel names
>    that are similar to publisher and subscribers.  The output port 
> name may
>    have wildcards, which may be matched by input ports.  Output ports may
>    have initial values.  If an output port does not have an initial 
> value,
>    then a default value of zero is used.  The actual default value 
> depends
>    on the token type.
> </p>
>
>    <p>The way the execution occurs is that during the first iteration,
>    the output ports are initialized with the initial values.  The 
> corresponding
>    input ports are then updated.  The actors are fired and the values
>    of the output ports are updated and the iteration ends.</p>
>
>    <p>This model of computation is similar to a Cellular Automaton model
>    of computation.  This model of computation differs from the
>    ptolemy/domains/ca/kernel/CADirector.java in that CADirector operates
>    on a matrix and the value of a cell is dependent on the values
>    of the adjacent values in the matrix.  In this model of computation,
>    values may depend on many different values.</p>
>
>    <p>This model of computation may be a subset of Linda.</p> 
However, Edward has recently updated Ptolemy II to include a 
PublisherPort that has an initialOutputs parameter that can act much 
like a SampleDelay.

See 
http://chess.eecs.berkeley.edu/ptexternal/src/ptII/doc/codeDoc/ptolemy/actor/PublisherPort.html

There is also a SubscriberPort for receiving these data from the 
PublisherPort.

We ended up removing the SPSDirector and are moving forward with 
PublisherPort and SubscriberPort.

This code was developed last month, and I'm actively working on it today.
There are various demos with the name 
ptolemy/actor/lib/test/auto/PublisherPort*.xml

To try out this code in Kepler, you would need to build a Kepler 
development version, see 
https://kepler-project.org/developers/teams/build/systems/build-system/extension-build-system

To instantiate a PublisherPort, start Kepler and do Tools -> Instantiate 
Entity and then type in the classname ptolemy.actor.PublisherPort
You will get an error message, but the PublisherPort will be created.

To view the tests from Kepler, File -> Open 
kepler/ptolemy/src/ptolemy/actor/lib/test/auto
and then open the various PublisherPort*.xml demos.

It would be interesting to implement some classic Linda models in 
Ptolemy II using the PublisherPorts.  I remember the article in 
Scientific American, but a quick search did not find it.  I'd be 
interested in getting feedback about how the 
PublisherPort/SubscriberPort compare and contrast with Linda

BTW - The Linda Wiki article says:
> Criticisms of Linda from the multiprocessing community tend to focus 
> on the decreased speed of operations in Linda systems as compared to 
> MPI systems.[citation needed] While not without justification, these 
> claims were largely refuted for an important class of problems.[2] 
> Detailed criticisms of the Linda model can also be found in Steven 
> Ericsson-Zenith's book Process Interaction Models.[3]
Edward's "Disciplined Message Passing" paper at 
http://chess.eecs.berkeley.edu/pubs/516.html might be of interest.

_Christopher



On 7/18/12 2:43 AM, Patrick Janssen wrote:
> I am interested in creating a Linda type of computational model, where 
> actors operate in parallel on data stored in and retrieved from 
> shared, virtual, associative memory.
> http://en.wikipedia.org/wiki/Linda_%28coordination_language%29
> http://en.wikipedia.org/wiki/Tuple_space
>
> What is the best way to do this? Any suggestions? (Or does Ptolemy 
> have features more suited to this?)
>
>
>
>
> _______________________________________________
> Kepler-users mailing list
> Kepler-users at kepler-project.org
> http://lists.nceas.ucsb.edu/kepler/mailman/listinfo/kepler-users

-- 
Christopher Brooks, PMP                       University of California
CHESS Executive Director                      US Mail: 337 Cory Hall
Programmer/Analyst CHESS/Ptolemy/Trust        Berkeley, CA 94720-1774
ph: 510.643.9841                                (Office: 545Q Cory)
home: (F-Tu) 707.665.0131 cell: 707.332.0670



-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.nceas.ucsb.edu/kepler/pipermail/kepler-users/attachments/20120720/d1eb7bfb/attachment-0001.html>


More information about the Kepler-users mailing list