Color Transfer Between Images, Histogram Based Style Transfer

color transfer
image manipulation
histogram-based style transfer
video effects
picture enhancement
Python code
image color matching
This text explains a method for color transfer between images, specifically using histogram-based style transfer to create vibrant effects in videos or pictures. It provides installation instructions and example Python code for image color matching using histogram matching.
Published

September 17, 2022


图像调色风格转换 可以创建蹦迪特效 让视频或者图片五彩斑斓

color transfer between images

pip install color_transfer

official scikit-learn histogram matching

import matplotlib.pyplot as plt
from skimage import data
from skimage import exposure
from skimage.exposure import match_histograms
reference = data.coffee()
image = data.chelsea()
matched = match_histograms(image, reference, channel_axis=-1)
fig, (ax1, ax2, ax3) = plt.subplots(nrows=1, ncols=3, figsize=(8, 3),
sharex=True, sharey=True)
for aa in (ax1, ax2, ax3):
aa.set_axis_off()
ax1.imshow(image)
ax1.set_title('Source')
ax2.imshow(reference)
ax2.set_title('Reference')
ax3.imshow(matched)
ax3.set_title('Matched')
plt.tight_layout()
plt.show()

histogram matching