Login using Social Account
     Continue with GoogleLogin using your credentials
With StyleContentModel
which is a style and content extractor, we can now implement the style transfer algorithm. Do this by calculating the mean square error for your image's output relative to each target, then take the weighted sum of these losses.
Let us set the style and content target values. We shall do this by extracting the style of the style image and content of the content image.
Get the target content from content_image
using extractor
as follows:
content_targets = extractor(content_image)['content']
Now similarly, get the target style from style_image
using extractor
.
style_targets = << your code comes here >>(style_image)['style']
Taking you to the next exercise in seconds...
Want to create exercises like this yourself? Click here.
Note - Having trouble with the assessment engine? Follow the steps listed here
Loading comments...