Bug #4519
openSDF Director cannot schedule when composite actor input port is disconnected
0%
Description
A workflow with an RExpression actor with unconnected input ports will work (see attached example 1). However, if I put that RExpression actor inside a composite actor (see attached example 2), the workflow can no longer be scheduled.
I'm not sure what the "correct" behavior is, but I like being able to have optional ports on RExpression actors and I like wrapping RExpression actors into composite actors, so I would prefer it if the composite actor could be scheduled with disconnected ports.
Files
Updated by Christopher Brooks about 15 years ago
Need a test case here.
Also, try selecting "Allow disconnected graphs" in the SDF director.
Updated by Christopher Brooks about 15 years ago
Ah, nevermind, I see the test cases.
Updated by Oliver Soong about 15 years ago
I tried disconnected graphs, but it still throws the error.
I realize it's a slightly complicated case, as the scheduler would need to check up the chain of ports to see whether it's actually connected. Of course, that code might be useful in general. There's a problem with report design and ports from composite actors, and it might be at least partially related to identifying the actual source port.
Updated by Christopher Brooks about 15 years ago
This Ptolemy model has a top level with a const connected to one port of a two port composite. Inside the composite, the two ports are connected to the plus and minus ports of an AddSubtract and the output is connected to a Display.
When the model is run, the error message is:
ptolemy.actor.sched.NotSchedulableException: Actors remain that cannot be scheduled!
Note that there are many reasons why a graph cannot be scheduled:- SDF Graphs with feedback loops should have an actor with a delay in the loop, such as a SampleDelay.* The SDF director has an "allowDisconnectedGraphs"parameter, which, when true, permits disconnected SDF graphs.
- The token consumption rate and production rates might be mismatched. Usually, actors produce one token or consume one token on a port. To produce or consume multiple tokens per firing, add a "tokenConsumptionRate" or "tokenConsumptionRate" parameter to the appropriate port.
For details, see the SDF chapter in Volume Three of the Ptolemy II design doc at http://ptolemy.eecs.berkeley.edu/ptolemyII/designdoc.htm
Unscheduled actors:
.sdfCompositeNoR.CompositeActor.Add or Subtract .sdfCompositeNoR.CompositeActor.Display
Scheduled actors:
.sdfCompositeNoR.Constant
The workaround is to not connect the inner connection that goes no where.
I'm not sure if this is a bug or an RFE. It is bug in that the model does
not behave as expected, even if the "Allow disconnected ports" is set.
It is an RFE in that the model has a disconnected port.