Skip to content

Latest commit

 

History

History
 
 

Style-Transfer

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 

Style Transfer Application

Style Transfer Application Using TensorFlow and TensorFlow Hub

This project implements a style transfer application that transforms images by combining the content of one image with the style of another using a pre-trained model from TensorFlow Hub.

Table of Contents

Requirements

To run this project, you will need:

  • Python 3.7+
  • TensorFlow 2.x+
  • TensorFlow Hub
  • Numpy
  • Matplotlib
  • Pillow

Installation

Clone the repository:

git clone https://github.com/your-repo/style-transfer.git
cd style-transfer

Install dependencies:

Install the required Python packages using pip:

pip install tensorflow tensorflow-hub numpy matplotlib pillow

Usage

Prepare the images:

Place the content and style images you want to process in the project directory. Ensure that the paths in the script point to these image files.

Run the script:

To run the style transfer application, use the following command:

python style_transfer.py

The script will apply the style of the style image to the content image and display the result.

Expected Output

The resulting image will display the content of the content image with the style of the style image applied.

Project Structure

.
├── style_transfer.py               # Main script to run style transfer
├── content_image.jpg               # Sample content image (replace with your own)
├── style_image.jpg                 # Sample style image (replace with your own)
└── README.md                       # This file

Models

The application uses the following pre-trained model from TensorFlow Hub:

Results

The model outputs an image that combines the content from the content image with the artistic style from the style image.

The output will be displayed using Matplotlib, showcasing the transformed image in a separate window.