import sys
import os
import pickle
goodOnes = ['python3 sim_mmns_2pm_sep_noISDIDD_savespikesonly.py 40 0.3 150 130 17.5 30.0 80.0 5.827500000000001 9.99 26.64 35.0 35.0 1000 0.0 0.95 10.0 10.0 10.0 250.0',
'python3 sim_mmns_2pm_sep_noISDIDD_savespikesonly.py 40 0.3 150 130 17.5 30.0 80.0 5.827500000000001 9.99 26.64 35.0 35.0 1000 0.0 0.9 10.0 10.0 10.0 250.0',
'python3 sim_mmns_2pm_sep_noISDIDD_savespikesonly.py 40 0.3 150 130 17.5 30.0 80.0 5.827500000000001 9.99 26.64 30.0 30.0 1000 0.0 0.95 10.0 10.0 10.0 250.0',
'python3 sim_mmns_2pm_sep_noISDIDD_savespikesonly.py 40 0.3 150 130 17.5 30.0 80.0 5.827500000000001 9.99 26.64 30.0 30.0 1000 0.0 0.9 10.0 10.0 10.0 250.0',
'python3 sim_mmns_2pm_sep_noISDIDD_savespikesonly.py 40 0.3 150 130 17.5 30.0 80.0 5.827500000000001 9.99 26.64 25.0 25.0 1000 0.0 0.95 10.0 10.0 10.0 250.0',
'python3 sim_mmns_2pm_sep_noISDIDD_savespikesonly.py 40 0.3 150 130 17.5 30.0 80.0 5.827500000000001 9.99 26.64 25.0 25.0 1000 0.0 0.9 10.0 10.0 10.0 250.0',
'python3 sim_mmns_2pm_sep_noISDIDD_savespikesonly.py 40 0.3 150 130 17.5 30.0 80.0 5.827500000000001 9.99 26.64 20.0 20.0 1000 0.0 0.9 10.0 10.0 10.0 250.0 ',
'python3 sim_mmns_2pm_sep_noISDIDD_savespikesonly.py 40 0.3 150 130 17.5 30.0 80.0 5.827500000000001 9.99 26.64 15.0 15.0 1000 0.0 0.95 10.0 10.0 10.0 250.0',
'python3 sim_mmns_2pm_sep_noISDIDD_savespikesonly.py 40 0.3 150 130 17.5 30.0 80.0 5.827500000000001 9.99 26.64 15.0 15.0 1000 0.0 0.9 10.0 10.0 10.0 250.0',
'python3 sim_mmns_2pm_sep_noISDIDD_savespikesonly.py 40 0.3 140 120 17.5 30.0 80.0 5.827500000000001 9.99 26.64 35.0 35.0 1000 0.0 0.9 10.0 10.0 10.0 250.0 ',
'python3 sim_mmns_2pm_sep_noISDIDD_savespikesonly.py 40 0.3 140 120 17.5 30.0 80.0 5.827500000000001 9.99 26.64 30.0 30.0 1000 0.0 0.9 10.0 10.0 10.0 250.0 ',
'python3 sim_mmns_2pm_sep_noISDIDD_savespikesonly.py 40 0.3 140 120 17.5 30.0 80.0 5.827500000000001 9.99 26.64 10.0 10.0 1000 0.0 0.9 10.0 10.0 10.0 250.0',
'python3 sim_mmns_2pm_sep_noISDIDD_savespikesonly.py 40 0.3 125 105 17.5 40.0 140.0 5.827500000000001 13.32 46.620000000000005 25.0 25.0 1000 0.0 0.9 10.0 10.0 10.0 250.0',
'python3 sim_mmns_2pm_sep_noISDIDD_savespikesonly.py 40 0.3 125 105 17.5 40.0 140.0 5.827500000000001 13.32 46.620000000000005 10.0 10.0 1000 0.0 0.9 10.0 10.0 10.0 250.0',
'python3 sim_mmns_2pm_sep_noISDIDD_savespikesonly.py 40 0.3 125 105 17.5 40.0 100.0 5.827500000000001 13.32 33.300000000000004 25.0 25.0 1000 0.0 0.9 10.0 10.0 10.0 200.0',
'python3 sim_mmns_2pm_sep_noISDIDD_savespikesonly.py 40 0.3 125 105 17.5 40.0 100.0 5.827500000000001 13.32 33.300000000000004 10.0 10.0 1000 0.0 0.9 10.0 10.0 10.0 200.0']
myseed = 1
if len(sys.argv) > 1:
myseed = int(sys.argv[1])
myseedAdd = '' if myseed == 1 else '_seed'+str(myseed)
areas = ['CTRL']
for iarea in [0]:
area = areas[iarea]
for imodel in range(0,len(goodOnes)):
attrs = goodOnes[imodel].split(' ')
mychange = [[[6,7,8,9,10,11],0.81]] #23% change suggested by https://pmc.ncbi.nlm.nih.gov/articles/PMC4454616/ ("The median reported decrease in spine density was 23% (range 6.5%-66%).")
#[3, '0.25'], [3, '0.2'], [3, '0.15'], [3, '0.1'], [3, '0.05'], [3, '0.0'], [3, '0.4'], [[9,10,11], '0.0'], [1, 'sim_mmns_2pm_sep_nopm2_savespikesonly.py'], [1, 'sim_mmns_2pm_sep_nopm2_nosep_savespikesonly.py'], [1, 'sim_mmns_2pm_sep_nopm2_nopm_savespikesonly.py'], [1, 'sim_mmns_2pm_sep_nopm2_nosep_nopm_savespikesonly.py'], [1, 'sim_mmns_2pm_sep_nodev_savespikesonly.py'], [1, 'sim_mmnothers_2pm_sep_savespikesonly.py'], [2, '30'], [2, '50'], [2, '20'], [2, '60'], [2, '80']]
these_attrs = attrs[:]
for ichange in range(0,len(mychange)):
if type(mychange[ichange][0]) is list:
for imany in range(0,len(mychange[ichange][0])):
these_attrs[mychange[ichange][0][imany]] = str(float(these_attrs[mychange[ichange][0][imany]])*mychange[ichange][1])
else:
these_attrs[mychange[ichange][0]] = str(float(these_attrs[mychange[ichange][0]])*mychange[ichange][1])
this_str = ' '.join(these_attrs)
print(this_str+' '+str(myseed))
os.system(this_str+' '+str(myseed))
print('mv MMNs_2pm_sep_noISDIDD_Nperpop'+these_attrs[2]+'_paramSD'+these_attrs[3]+'_stimA'+these_attrs[4]+'_'+these_attrs[5]+'_gAMPA'+these_attrs[6]+'_'+these_attrs[7]+'_'+these_attrs[8]+'_gNMDA'+these_attrs[9]+'_'+these_attrs[10]+'_'+these_attrs[11]+'_gGABA'+these_attrs[12]+'_'+these_attrs[13]+'_dep'+these_attrs[14]+'_'+these_attrs[15]+'_'+these_attrs[16]+'_tau'+these_attrs[17]+'_'+these_attrs[18]+'_'+these_attrs[19]+'_'+these_attrs[20]+myseedAdd+'.mat MMNs_2pm_sep_noISDIDD_19percentMorePruned_model'+str(imodel)+'_'+area+'pop_seed'+str(myseed)+'.mat')
os.system('mv MMNs_2pm_sep_noISDIDD_Nperpop'+these_attrs[2]+'_paramSD'+these_attrs[3]+'_stimA'+these_attrs[4]+'_'+these_attrs[5]+'_gAMPA'+these_attrs[6]+'_'+these_attrs[7]+'_'+these_attrs[8]+'_gNMDA'+these_attrs[9]+'_'+these_attrs[10]+'_'+these_attrs[11]+'_gGABA'+these_attrs[12]+'_'+these_attrs[13]+'_dep'+these_attrs[14]+'_'+these_attrs[15]+'_'+these_attrs[16]+'_tau'+these_attrs[17]+'_'+these_attrs[18]+'_'+these_attrs[19]+'_'+these_attrs[20]+myseedAdd+'.mat MMNs_2pm_sep_noISDIDD_19percentMorePruned_model'+str(imodel)+'_'+area+'pop_seed'+str(myseed)+'.mat')