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
43f5fa0e
Commit
43f5fa0e
authored
Oct 01, 2014
by
Georgios Dagkakis
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
change so that the batches instance works correct with the daily attainment
parent
ea7d1aa9
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
10 additions
and
3 deletions
+10
-3
dream/simulation/EventGenerator.py
dream/simulation/EventGenerator.py
+9
-2
dream/simulation/Globals.py
dream/simulation/Globals.py
+1
-1
No files found.
dream/simulation/EventGenerator.py
View file @
43f5fa0e
...
@@ -38,10 +38,17 @@ class EventGenerator(ObjectInterruption):
...
@@ -38,10 +38,17 @@ class EventGenerator(ObjectInterruption):
self
.
name
=
name
self
.
name
=
name
self
.
start
=
float
(
start
)
#the time that the generator will be activated for the first time
self
.
start
=
float
(
start
)
#the time that the generator will be activated for the first time
self
.
stop
=
float
(
stop
)
#the time that the generator will stop to trigger events
self
.
stop
=
float
(
stop
)
#the time that the generator will stop to trigger events
# negative stop means infinity
if
self
.
stop
<
0
:
self
.
stop
=
float
(
'inf'
)
self
.
interval
=
float
(
interval
)
#the interval that the generator sleeps
self
.
interval
=
float
(
interval
)
#the interval that the generator sleeps
self
.
duration
=
float
(
duration
)
#the duration that the generation is awake (this is not active for now)
self
.
duration
=
float
(
duration
)
#the duration that the generation is awake (this is not active for now)
self
.
method
=
method
#the method to be invoked
self
.
method
=
method
#the method to be invoke
self
.
argumentDict
=
argumentDict
#the arguments of the method given in a dict
self
.
argumentDict
=
argumentDict
# if the argumentDict is passed as string convert it to dict
if
isinstance
(
self
.
argumentDict
,
basestring
):
import
ast
self
.
argumentDict
=
ast
.
literal_eval
(
self
.
argumentDict
)
from
Globals
import
G
from
Globals
import
G
G
.
EventGeneratorList
.
append
(
self
)
G
.
EventGeneratorList
.
append
(
self
)
self
.
method
=
method
self
.
method
=
method
...
...
dream/simulation/Globals.py
View file @
43f5fa0e
...
@@ -300,7 +300,7 @@ def setWIP(entityList):
...
@@ -300,7 +300,7 @@ def setWIP(entityList):
entity
.
currentStation
.
expectedSignals
[
'initialWIP'
]
=
0
entity
.
currentStation
.
expectedSignals
[
'initialWIP'
]
=
0
def
countIntervalThroughput
():
def
countIntervalThroughput
(
**
kw
):
from
Exit
import
Exit
from
Exit
import
Exit
currentExited
=
0
currentExited
=
0
for
obj
in
G
.
ObjList
:
for
obj
in
G
.
ObjList
:
...
...
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