Giter Site home page Giter Site logo

spenhouet / automated-deep-photo-style-transfer Goto Github PK

View Code? Open in Web Editor NEW
106.0 106.0 36.0 15.28 MB

TensorFlow implementation for the paper "Automated Deep Photo Style Transfer"

Home Page: https://arxiv.org/abs/1901.03915

Python 100.00%
deep-learning neural-networks segmentation style-transfer tensorflow

automated-deep-photo-style-transfer's Introduction

Hi My name is Sebastian Penhouet

Head of R&D at AIRAmed GmbH

My current main focus is on machine learning in the area of medical image segmentation. On the side I'm also a web dev and experimenting with web3 technologies.

Skills

Python TypeScript JavaScript Java Svelte TailwindCSS HTML5 CSS3 PostgreSQL Fast API

Socials

automated-deep-photo-style-transfer's People

Contributors

avodo avatar patwie avatar paulsans avatar spenhouet avatar vinno97 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

automated-deep-photo-style-transfer's Issues

Specify python version

For the time I was running your project in python 3.5 but throws an error in sematch library as follows.
from sematch.semantic.similarity import WordNetSimilarity
Traceback (most recent call last):
File "", line 1, in
File "C:\Users\Siyas\AppData\Local\Continuum\anaconda3\lib\site-packages\sematch\semantic\similarity.py", line 25, in
from sematch.semantic.sparql import EntityFeatures, StatSPARQL
File "C:\Users\Siyas\AppData\Local\Continuum\anaconda3\lib\site-packages\sematch\semantic\sparql.py", line 36
print query
^
SyntaxError: Missing parentheses in call to 'print'. Did you mean print(print query)?

The fix was to give a parenthesis to that file specified. But thats not the fix. Please tell me how did it work for you.

Document for parameters?

Is there any example of how to use style_transfer? Perhaps an explanation on the parameters as well. Thanks!

How to start the program?

I have followed the instructions in the Read Me section (steps 1 - 4). However, I'm not quite sure how to start the program. In Google Colab I have:

from PIL import Image
base_image = Image.open('/content/drive/My Drive/base.jpg')
style_image = Image.open('/content/drive/My Drive/style.jpg')

# pass arguments to script
!python style_transfer.py --base_image --style_image

It currently returns an unexpected argument error. Any thoughts on how I should proceed?

Licence

Under what conditions can I obtain a license for commercial use?

Some images run well. However some images could not run,why?

Using TensorFlow backend.
Create segmentation.
Compute segmentation started
2019-04-30 14:23:14.863543: I tensorflow/core/platform/cpu_feature_guard.cc:141] Your CPU supports instructions that this TensorFlow binary was not compiled to use: AVX2 FMA
2019-04-30 14:23:15.033646: I tensorflow/stream_executor/cuda/cuda_gpu_executor.cc:998] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero
2019-04-30 14:23:15.034140: I tensorflow/compiler/xla/service/service.cc:150] XLA service 0x56271ea411e0 executing computations on platform CUDA. Devices:
2019-04-30 14:23:15.034171: I tensorflow/compiler/xla/service/service.cc:158] StreamExecutor device (0): Tesla T4, Compute Capability 7.5
2019-04-30 14:23:15.035899: I tensorflow/core/platform/profile_utils/cpu_utils.cc:94] CPU Frequency: 2300000000 Hz
2019-04-30 14:23:15.036179: I tensorflow/compiler/xla/service/service.cc:150] XLA service 0x56271ea41080 executing computations on platform Host. Devices:
2019-04-30 14:23:15.036208: I tensorflow/compiler/xla/service/service.cc:158] StreamExecutor device (0): ,
2019-04-30 14:23:15.036524: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1433] Found device 0 with properties:
name: Tesla T4 major: 7 minor: 5 memoryClockRate(GHz): 1.59
pciBusID: 0000:00:04.0
totalMemory: 14.73GiB freeMemory: 14.60GiB
2019-04-30 14:23:15.036551: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1512] Adding visible gpu devices: 0
2019-04-30 14:23:15.037080: I tensorflow/core/common_runtime/gpu/gpu_device.cc:984] Device interconnect StreamExecutor with strength 1 edge matrix:
2019-04-30 14:23:15.037100: I tensorflow/core/common_runtime/gpu/gpu_device.cc:990] 0
2019-04-30 14:23:15.037110: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1003] 0: N
2019-04-30 14:23:15.037329: W tensorflow/core/common_runtime/gpu/gpu_bfc_allocator.cc:42] Overriding allow_growth setting because the TF_FORCE_GPU_ALLOW_GROWTH environment variable is set. Original config value was 0.
2019-04-30 14:23:15.037366: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1115] Created TensorFlow device (/job:localhost/replica:0/task:0/device:GPU:0 with 14202 MB memory) -> physical GPU (device: 0, name: Tesla T4, pci bus id: 0000:00:04.0, compute capability: 7.5)
WARNING:tensorflow:From /usr/local/lib/python2.7/dist-packages/tensorflow/python/framework/op_def_library.py:263: colocate_with (from tensorflow.python.framework.ops) is deprecated and will be removed in a future version.
Instructions for updating:
Colocations handled automatically by placer.
WARNING:tensorflow:From /content/automated-deep-photo-style-transfer/components/PSPNet/network.py:263: batch_normalization (from tensorflow.python.layers.normalization) is deprecated and will be removed in a future version.
Instructions for updating:
Use keras.layers.batch_normalization instead.
WARNING:tensorflow:From /usr/local/lib/python2.7/dist-packages/tensorflow/python/util/dispatch.py:180: calling expand_dims (from tensorflow.python.ops.array_ops) with dim is deprecated and will be removed in a future version.
Instructions for updating:
Use the axis argument instead
WARNING:tensorflow:From /usr/local/lib/python2.7/dist-packages/tensorflow/python/training/saver.py:1266: checkpoint_exists (from tensorflow.python.training.checkpoint_management) is deprecated and will be removed in a future version.
Instructions for updating:
Use standard file APIs to check for files with this prefix.
Restored model parameters from /content/automated-deep-photo-style-transfer/weights/PSPNet/checkpoint/model.ckpt-0
2019-04-30 14:23:19.381974: I tensorflow/stream_executor/dso_loader.cc:152] successfully opened CUDA library libcublas.so.10.0 locally
Semantic merge of segments started
Semantic merge of different segments started
Semantic merge of different segments started
Traceback (most recent call last):
File "/content/automated-deep-photo-style-transfer/style_transfer.py", line 322, in
args.semantic_thresh)
File "/content/automated-deep-photo-style-transfer/components/semantic_merge.py", line 93, in merge_segments
assert style_colors == content_colors
AssertionError

miss import

model.py file miss import numpy as np and import tensorflow as tf

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.