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
10308468
Commit
10308468
authored
Sep 05, 2013
by
Georgios Dagkakis
Committed by
Sebastien Robin
Sep 30, 2013
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
cleanup, unused methods removed
parent
38fcc358
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
2 additions
and
23 deletions
+2
-23
dream/simulation/Conveyer.py
dream/simulation/Conveyer.py
+1
-1
dream/simulation/Dismantle.py
dream/simulation/Dismantle.py
+0
-9
dream/simulation/Machine.py
dream/simulation/Machine.py
+0
-8
dream/simulation/Queue.py
dream/simulation/Queue.py
+1
-5
No files found.
dream/simulation/Conveyer.py
View file @
10308468
...
...
@@ -233,7 +233,7 @@ class Conveyer(CoreObject):
totalLength
+=
self
.
Res
.
activeQ
[
i
].
length
return
self
.
length
<
totalLength
#checks if the Mover shoul be called so that the move is performed
#checks if the Mover shoul
d
be called so that the move is performed
def
callMover
(
self
):
return
self
.
call
...
...
dream/simulation/Dismantle.py
View file @
10308468
...
...
@@ -341,14 +341,5 @@ class Dismantle(CoreObject):
json
[
'results'
][
'waiting_ratio'
][
'max'
]
=
self
.
Waiting
[
0
]
G
.
outputJSON
[
'elementList'
].
append
(
json
)
#takes the array and checks if all its values are identical (returns false) or not (returns true)
#needed because if somebody runs multiple runs in deterministic case it would crash!
def
checkIfArrayHasDifValues
(
self
,
array
):
difValuesFlag
=
False
for
i
in
range
(
1
,
len
(
array
)):
if
(
array
[
i
]
!=
array
[
1
]):
difValuesFlag
=
True
return
difValuesFlag
\ No newline at end of file
dream/simulation/Machine.py
View file @
10308468
...
...
@@ -188,14 +188,6 @@ class Machine(CoreObject):
self
.
totalBlockageTime
+=
totalTime
-
(
tinMStart
+
failureTime
)
#the time of blockage is derived from
#the whole time in the machine
#minus the processing time and the failure time
#checks if the waitQ of the machine is empty
def
checkIfWaitQEmpty
(
self
):
return
len
(
self
.
M
.
waitQ
)
==
0
#checks if the activeQ of the machine is empty
def
checkIfActiveQEmpty
(
self
):
return
len
(
self
.
M
.
activeQ
)
==
0
#checks if the machine is Up
def
checkIfMachineIsUp
(
self
):
return
self
.
Up
...
...
dream/simulation/Queue.py
View file @
10308468
...
...
@@ -89,11 +89,7 @@ class Queue(CoreObject):
#if entity just got to the dummyQ set its startTime as the current time
if
self
.
isDummy
:
self
.
Res
.
activeQ
[
0
].
startTime
=
now
()
#checks if the Q has one available place
def
checkIfQHasPlace
(
self
):
return
len
(
self
.
Q
.
activeQ
)
<
self
.
capacity
#checks if the Queue can accept an entity
#it checks also who called it and returns TRUE only to the predecessor that will give the entity.
def
canAccept
(
self
):
...
...
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