Skip to content

Commit

Permalink
A print instuction multiplies the prints of '''Execution Mode: single…
Browse files Browse the repository at this point in the history
…_proc: [<cadCAD.configuration.Configuration object at ..'''
  • Loading branch information
mariopaolucci committed Mar 15, 2020
1 parent dc90331 commit 4cdb38e
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions Fin4_ABM.py
Original file line number Diff line number Diff line change
Expand Up @@ -280,7 +280,8 @@ def random_claim_of_tokens(params, step, sL, s):
if len(pats_careless_opp) >= 1:
total_pats = pats_careless_malicious

claim(ch, total_pats, 'no_activity', s)
claim(ch, total_pats, 'no_activity', s)
print(opportunistic_agents_claiming)

return {'update_agents': {'update': compliant_agents_claiming},
'update_agents': {'update': opportunistic_agents_claiming},
Expand All @@ -290,7 +291,7 @@ def random_claim_of_tokens(params, step, sL, s):
def create_pat(params, step, sL, s):
agents = s['agents']
initial_PAT_nr = len(s['PATs'])
print("timestep", s['timestep'])
print("!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!1--!!!!!!------------------------timestep", s['timestep'])
#creation_frequency = config['PAT agents']['number_initial_pats'] #config['PAT agents']['frequency_PAT_creation']
print('creation frequency: ', creation_frequency)

Expand Down Expand Up @@ -421,6 +422,6 @@ def update_agents(params, step, sL, s, _input):
raw_result, tensor = executor.execute()


with open("output.json", 'a') as result_file:
with open("output.json", 'w') as result_file:
result_file.write('\n' + str(raw_result) + '\n')
result_file.close()

0 comments on commit 4cdb38e

Please sign in to comment.