Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
dream
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
1
Issues
1
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
dream
Commits
2d7033c8
Commit
2d7033c8
authored
May 20, 2014
by
Ioannis Papagiannopoulos
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
comments clean-up
parent
1eea3343
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
0 additions
and
37 deletions
+0
-37
dream/simulation/CoreObject.py
dream/simulation/CoreObject.py
+0
-8
dream/simulation/Machine.py
dream/simulation/Machine.py
+0
-8
dream/simulation/ObjectInterruption.py
dream/simulation/ObjectInterruption.py
+0
-21
No files found.
dream/simulation/CoreObject.py
View file @
2d7033c8
...
@@ -650,14 +650,6 @@ class CoreObject(Process):
...
@@ -650,14 +650,6 @@ class CoreObject(Process):
def
activeQueueIsEmpty
(
self
):
def
activeQueueIsEmpty
(
self
):
return
len
(
self
.
Res
.
activeQ
)
==
0
return
len
(
self
.
Res
.
activeQ
)
==
0
# # =======================================================================
# # checks if the object is ready to receive an Entity
# # =======================================================================
# def isReadyToGet(self):
# return True # set to true since this control was not needed until now.
# # to return canAcceptAndIsRequested() would be more logical, but also computationally expensive
# #return self.canAcceptAndIsRequested()
# =======================================================================
# =======================================================================
# actions to be carried out when the processing of an Entity ends
# actions to be carried out when the processing of an Entity ends
# =======================================================================
# =======================================================================
...
...
dream/simulation/Machine.py
View file @
2d7033c8
...
@@ -455,9 +455,6 @@ class Machine(CoreObject):
...
@@ -455,9 +455,6 @@ class Machine(CoreObject):
# if while waiting (for a canDispose event) became free as the machines that follows emptied it, then proceed
# if while waiting (for a canDispose event) became free as the machines that follows emptied it, then proceed
if
not
self
.
haveToDispose
():
if
not
self
.
haveToDispose
():
break
break
# TODO: in operated Machine, sometimes the giver is not signalled from the removeEntity method because there
# there was no operator available. In this case, by the time the operator is available again the Machine
# must receive the entity from the predecessor and thus the
# =======================================================================
# =======================================================================
# actions to be carried out when the processing of an Entity ends
# actions to be carried out when the processing of an Entity ends
...
@@ -475,13 +472,8 @@ class Machine(CoreObject):
...
@@ -475,13 +472,8 @@ class Machine(CoreObject):
activeObject
.
outputTrace
(
activeObject
.
getActiveObjectQueue
()[
0
].
name
,
"ended processing in "
+
activeObject
.
objName
)
activeObject
.
outputTrace
(
activeObject
.
getActiveObjectQueue
()[
0
].
name
,
"ended processing in "
+
activeObject
.
objName
)
except
IndexError
:
except
IndexError
:
pass
pass
# the entity that just got processed is cold again it will get
# hot again by the time it reaches the giver of the next machine
# TODO: Not only Machines require time to process entities
# TODO: Not only Machines require time to process entities
# entities such as batchReassembly/Decomposition require time to process entities
# entities such as batchReassembly/Decomposition require time to process entities
# TODO: We must consider also the case that entities can be blocked before they can reach
# the heating point. In such a case they must be removed from the G.pendingEntities list
# and added again after they are unblocked
if
activeEntity
.
family
==
'Entity'
:
if
activeEntity
.
family
==
'Entity'
:
successorsAreMachines
=
True
successorsAreMachines
=
True
from
Globals
import
G
from
Globals
import
G
...
...
dream/simulation/ObjectInterruption.py
View file @
2d7033c8
...
@@ -59,26 +59,6 @@ class ObjectInterruption(Process):
...
@@ -59,26 +59,6 @@ class ObjectInterruption(Process):
def
invoke
(
self
):
def
invoke
(
self
):
self
.
isCalled
.
signal
(
now
())
self
.
isCalled
.
signal
(
now
())
# # =======================================================================
# # return control to the Machine.run
# # =======================================================================
# def exit(self):
# self.call=False
# # =======================================================================
# # call the objectInterruption
# # filter for object interruption - yield waituntil isCalled
# # =======================================================================
# def isCalled(self):
# return self.call
# # =======================================================================
# # the objectIterruption returns control to machine.Run
# # filter for Machine - yield request/release operator
# # =======================================================================
# def isSet(self):
# return not self.call
#===========================================================================
#===========================================================================
# outputs data to "output.xls"
# outputs data to "output.xls"
#===========================================================================
#===========================================================================
...
@@ -119,7 +99,6 @@ class ObjectInterruption(Process):
...
@@ -119,7 +99,6 @@ class ObjectInterruption(Process):
#===========================================================================
#===========================================================================
def
reactivateVictim
(
self
):
def
reactivateVictim
(
self
):
self
.
victim
.
interruptionEnd
.
signal
(
now
())
self
.
victim
.
interruptionEnd
.
signal
(
now
())
# reactivate(self.victim)
#===========================================================================
#===========================================================================
# outputs message to the trace.xls. Format is (Simulation Time | Victim Name | message)
# outputs message to the trace.xls. Format is (Simulation Time | Victim Name | message)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment