I was thinking more like
consider two nets with only difference in parameters : net_1.ptototxt and net_2.ptototxt
turn = 0
net_1 = caffe.Net(net_1.prototxt, caffe.TRAIN)
net_2 = caffe.Net(net_2.prototxt, caffe.TRAIN)
solver = caffe.get_solver(solver_net_1)
if turn is 0:
solver.step(1) # I have doubt that...will this step(1) also change the network input data (next batch) for next step?
x = solver.net.blobs['data'].data[...] # saving input data for second network step
if turn is 1:
solver.net.blobs['data'].data[...] = x # for running second net on same data as first net
solver.step(1)
#change the turn
turn = (turn+1)%2
Please suggest whether this will work or not? it will go for 2*max_iter in this way.