present_coefiecients = random.sample(xrange(1,50),5)
present_value = random.sample(xrange(1,100),5)
present_weights = ap.array('0;0;0;0;0')
print present_coefiecients
print present_value
print present_weights
c = [a*b for a,b in zip(present_coefiecients,present_value)]
layer_1 = ap.log2(c)
print layer_1
如何将这些指令集运行50次,以便每次都能得到不同的层1的值
好吧,为此只需使用
for
循环:相关问题 更多 >
编程相关推荐