{"id":23734635,"url":"https://github.com/devkihyun/neural-style-transfer-tensorflow-keras","last_synced_at":"2026-03-02T03:04:05.451Z","repository":{"id":250129824,"uuid":"187775970","full_name":"DevKiHyun/Neural-Style-Transfer-Tensorflow-Keras","owner":"DevKiHyun","description":"Tensorflow(using keras pretrained model) implementation of 'Image Style Transfer Using Convolutional Neural Networks'","archived":false,"fork":false,"pushed_at":"2019-07-09T12:05:29.000Z","size":5306,"stargazers_count":6,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-07-09T10:49:09.333Z","etag":null,"topics":["deep-neural-networks","keras","python","style-transfer","tensorflow"],"latest_commit_sha":null,"homepage":"","language":"Jupyter Notebook","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/DevKiHyun.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-05-21T06:34:14.000Z","updated_at":"2020-07-27T10:48:34.000Z","dependencies_parsed_at":"2024-07-25T11:10:39.773Z","dependency_job_id":"a27fece3-8676-4bbe-9542-634c8b1125c1","html_url":"https://github.com/DevKiHyun/Neural-Style-Transfer-Tensorflow-Keras","commit_stats":null,"previous_names":["devkihyun/neural-style-transfer-tensorflow-keras"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/DevKiHyun/Neural-Style-Transfer-Tensorflow-Keras","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DevKiHyun%2FNeural-Style-Transfer-Tensorflow-Keras","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DevKiHyun%2FNeural-Style-Transfer-Tensorflow-Keras/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DevKiHyun%2FNeural-Style-Transfer-Tensorflow-Keras/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DevKiHyun%2FNeural-Style-Transfer-Tensorflow-Keras/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/DevKiHyun","download_url":"https://codeload.github.com/DevKiHyun/Neural-Style-Transfer-Tensorflow-Keras/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DevKiHyun%2FNeural-Style-Transfer-Tensorflow-Keras/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29991299,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-02T01:47:34.672Z","status":"online","status_checked_at":"2026-03-02T02:00:07.342Z","response_time":60,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["deep-neural-networks","keras","python","style-transfer","tensorflow"],"created_at":"2024-12-31T05:46:22.734Z","updated_at":"2026-03-02T03:04:05.435Z","avatar_url":"https://github.com/DevKiHyun.png","language":"Jupyter Notebook","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Neural Style Transfer-TF\u0026Keras (2019/05/20)\n\n## Introduction\nI implement a tensorflow\u0026keras model described in the papers\n- [\"A Neural Algorithm of Artistic Style\"](https://arxiv.org/pdf/1508.06576v2.pdf).\n- [\"Image Style Transfer Using Convolutional Neural Networks\", CVPR 2016](https://www.cv-foundation.org/openaccess/content_cvpr_2016/papers/Gatys_Image_Style_Transfer_CVPR_2016_paper.pdf). by Leon A. Gatys, Alexander S. Ecker, Matthias Bethge\n\n## Environment\n- Ubuntu 16.04\n- Python 3.6\n\n## Depenency\n- Numpy\n- Opencv2\n- Matplotlib\n- Tensorflow (1.4 \u003c= x \u003c=1.13)\n\n## Files\n- `images(dir)` : images for style transfer.\n- `neural_style_transfer.py` : main code for style transfer.\n- `neural_style_transfer.ipynb` : you can execute this code on jupyternotebook. recommend 'Colab' of Google.\n\n## How to use\n#### Running\n```\npython neural_style_transfer.py --content_image_path \u003ccontent image path\u003e --style_image_path \u003cstyle image path\u003e\n# ex)\npython neural_style_transfer.py --content_image_path images/content/tubingen.jpg --style_image_path images/style/starry-night.jpg\n```\n\n#### Arguments\n*Required* :  \n- `--content_image_path`: Path of the content image. *Default*: `images/content/tubingen.jpg`\n- `--style_image_path`: Path of the style image. *Default*: `images/style/starry-night.jpg`\n\n*Optional* :  \n- `--model_type`: Type of pretrained model. *Choices*: 0(VGG16), 1(VGG19) *Default*: `0`\n- `--image_resize`: Resize(int or tuple) images. *Default*: `512`\n- `--rescale_image`: Rescale the final image to original size. *Default*: `False`\n- `--content_blocks`: Layer list for feature vector of Content image. *Default*: `['block4_conv2']`\n- `--style_blocks`: Layer list for feature vector of Style image. *Default*: `['block1_conv1', 'block2_conv1', 'block3_conv1', 'block4_conv1', 'block5_conv1']`\n- `--loss_ratio`: Weight of content-loss relative to style-loss. Alpha over beta in the paper. *Default*: `1e-3`\n- `--total_variation_weight`: Total Variation weight. *Default*: `0 (If you want to use this, then 8.5e-5)`\n- `--initial_type`: The initial image to generate image. *Choices*: content, style, random. *Default*: `'random'`\n- `--optimizer_type`: The optimizer for optimization. *Choices*: 0(Adam Optimizer), 1(L-BFGS-B Optimizer). *Default*: `1`\n- `--learning_rate`: The value of learning rate for Adam Optimizer. *Default*: `1e+1`\n- `--beta_1`: Beta_1 of Adam Optimizer. *Default*: `0.9`\n- `--beta_2`: Beta_2 of Adam Optimizer. *Default*: `0.999`\n- `--epsilon`: Epsilon of Adam Optimizer. *Default*: `1e-08`\n- `--iteration`: The number of iterations. *Default*: `150`\n\n## Sample results\n### Content Image : Tübingen, Germany\n### Style Image : starry-night, seated-nude, shipwreck, kandinsky, the_scream\nAll of results made from default setting and executed on Colab.\n\n\u003cp align=\"center\"\u003e\n\u003cimg src=\"images/content/tubingen.jpg\" height=\"192px\"\u003e\n\u003cimg src=\"images/sample/tubingen_shipwreck.jpg\" height=\"192px\"\u003e\n\u003cimg src=\"images/sample/tubingen_starry_night.jpg\" height=\"192px\"\u003e\n\n\u003cimg src=\"images/sample/tubingen_seated_nude.jpg\" height=\"192px\"\u003e\n\u003cimg src=\"images/sample/tubingen_the_scream.jpg\" height=\"192px\"\u003e\n\u003cimg src=\"images/sample/tubingen_kandinsky.jpg\" height=\"192px\"\u003e\n\u003c/p\u003e\n\n### Content Image : \n#### Female Knight ([source](https://www.artstation.com/artwork/4zXxW))\n\n#### blue-moon-lake ([source](https://github.com/titu1994/Neural-Style-Transfer))\n\n### Style Image : wave\nAll of results made from default setting and executed on Colab.\n\n\u003c/p\u003e\n\u003cp align='center'\u003e\n\u003cimg src = 'images/content/blue-moon-lake.jpg' height = '210px'\u003e\n\u003cimg src = 'images/style/wave.jpg' height = '210px'\u003e\n\u003cbr\u003e\n\u003cimg src = 'images/sample/blue_moon_lake_wave.jpg' '365px' width = '710px'\u003e\n\u003cbr\u003e\n\u003cimg src = 'images/content/female_knight.jpg' height = '210px'\u003e\n\u003cimg src = 'images/style/wave.jpg' height = '210px'\u003e\n\u003cbr\u003e\n\u003cimg src = 'images/sample/female_knight_wave.png' height = '365px' width = '710px'\u003e\n\u003c/p\u003e\n\n\n## Reference\n#### https://github.com/anishathalye/neural-style.\n\n#### https://github.com/titu1994/Neural-Style-Transfer\n\n#### https://github.com/hwalsuklee/tensorflow-style-transfer\n\n#### https://github.com/cysmith/neural-style-tf\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdevkihyun%2Fneural-style-transfer-tensorflow-keras","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdevkihyun%2Fneural-style-transfer-tensorflow-keras","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdevkihyun%2Fneural-style-transfer-tensorflow-keras/lists"}