Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- inputs = np.array([23.,56,69])
- def DoModel(array):
- ... do magic ...
- return newArray
- Outputs= np.array([np.array([DoModel(inputs) for x in xrange(iterations)])
- def RunModel(iterations, inputs):
- # generate a 1D array of length iteration containing the input array
- myArray = np.full((1,int(iterations)), inputs)
- Outputs = RunModel(iterations, inputs)
- # run my function on the array
- return DoModel(empty)
- ValueError: could not broadcast input array from shape (3) into shape (1,5)
- myArray = np.full((1,int(iterations)), inputs,dtype=np.ndarray
- )
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement