for x in range (1, 10)
for y in range (1,10)
for z in range (1,10)
#In this loop, I perform some operations to generate an
#output that has a shape (500,4). By using this output, I perform
#another set of operations as shown below)
for i in range(1,500)
if i == 20
p = somevalue_1 #(which is derived by using columns in outpout(500,4)
if i == 40
q = somevalue_2 #(which is derived by using columns in outpout(500,4)
if i == 60
r = somevalue_3 #(which is derived by using columns in outpout(500,4)
if i == 80
s = somevalue_4 #(which is derived by using columns in outpout(500,4)
Итак, для 1000 итераций (10x10x10) я хочу собрать значения p, q, r, s (shape (1000,4)).