This diagonal array of Necker cubes has been processed in an iterative fashion with the Google DeepDream algorithm which has been implemented in Python. A code snippet can be found below and the full source code is available on GitHub.
https://github.com/google/deepdream
An interesting question is: If an AI creates a work of art, who owns the rights to it?
2017). If an AI creates a work of art, who owns the rights to it?
. (Show/hide publication abstract
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 |
def objective_L2(dst): dst.diff[:] = dst.data def make_step(net, step_size=1.5, end='inception_4c/output', jitter=32, clip=True, objective=objective_L2): '''Basic gradient ascent step.''' src = net.blobs['data'] # input image is stored in Net's 'data' blob dst = net.blobs[end] ox, oy = np.random.randint(-jitter, jitter+1, 2) src.data[0] = np.roll(np.roll(src.data[0], ox, -1), oy, -2) # apply jitter shift net.forward(end=end) objective(dst) # specify the optimization objective net.backward(start=end) g = src.diff[0] # apply normalized ascent step to the input image src.data[:] += step_size/np.abs(g).mean() * g src.data[0] = np.roll(np.roll(src.data[0], -ox, -1), -oy, -2) # unshift image if clip: bias = net.transformer.mean['data'] src.data[:] = np.clip(src.data, -bias, 255-bias) |
References
2015). Research Blog: DeepDream – a code example for visualizing Neural Networks . (
Plain numerical DOI: 10.1111/j.1600-6143.2012.04033.x.The
DOI URL
directSciHub download
Show/hide publication abstract
2015). TensorFlow – Google’s latest machine learning system, open sourced for everyone . (