-
Notifications
You must be signed in to change notification settings - Fork 42
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Server priorities bug #200
Comments
Hi there @srinath-radhakrishnan I am not sure I fully understand what your model looks like. Correct me if I'm wrong but my understanding is that you have two classes of customers:
and you want to prioritise your servers for both classes in such a way so that if:
One way of doing that is: import random
import ciw
def custom_server_priority(srv, ind):
if ind.customer_class == 0:
priorities = {1: 0, 2: random.random(), 3: random.random()}
return priorities[srv.id_number]
if ind.customer_class == 1:
priorities = {1: 1, 2: random.random(), 3: random.random()}
return priorities[srv.id_number]
N = ciw.create_network(
arrival_distributions={
"Class 0": [ciw.dists.Exponential(1)],
"Class 1": [ciw.dists.Exponential(1)],
},
service_distributions={
"Class 0": [ciw.dists.Exponential(2)],
"Class 1": [ciw.dists.Exponential(2)],
},
number_of_servers=[3],
server_priority_functions=[custom_server_priority],
) Is that similar to what you have? If not, can you show me how you defined your network object? |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi, when using server priorities by individual - I'm facing 2 issues.
Can someone please help me here?
The text was updated successfully, but these errors were encountered: