SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2408.16450 · 2024

What to Preserve and What to Transfer: Faithful, Identity-Preserving Diffusion-based Hairstyle Transfer

arXiv · PDF · Open in the Atlas

Code that ran

7 of 9 samples (functions and classes) lifted from this paper's linked repositories executed on a synthesized input in Syntology's jail (0 of them constructed an object rather than computing a result; 2 honoured the contract we drafted, 0 violated it and 0 have no contract verdict; 5 failures of our instrument; 2 no recorded run), measured 2026-11-22; repository links from the Papers with Code archive attributed under CC BY-SA, no affiliation; bodies inline only under a permissive licence as GitHub detects it. Not a reproduction of the paper's results.

"Ran" means the function executed on a synthesized input and returned a value. It is not a reproduction of the paper's results. This record, dated, as JSON: /api/ran/2408.16450.json · badge: /api/ran/2408.16450.svg

Each repository's role is a label: a classifier's output recorded on the link, or, where no role is recorded, what the Papers with Code archive marked. The line under it names its basis. Neither says who wrote the code.

RepositoryRoleRan
cychungg/hairfusion canonical (classifier label)
classifier basis: census
7 ran · 2 no recorded run
FunctionStatusWhere it lives
build_config Ran
ran; our contract draft was wrong, not the code
cychungg/hairfusion/inference.py
pointer only (licence: NONE) · get_code("cb0c1205020f5f67")
How it ran

The body of this sample is withheld: GitHub detected no licence in this paper's repository, cychungg/hairfusion when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

get_fn Ran
ran; our contract draft was wrong, not the code
cychungg/hairfusion/dataset.py
pointer only (licence: NONE) · get_code("a92e42c28a066d4e")
How it ran

The body of this sample is withheld: GitHub detected no licence in this paper's repository, cychungg/hairfusion when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

get_state_dict Ran
ran; our contract draft was wrong, not the code
cychungg/hairfusion/cldm/model.py
pointer only (licence: NONE) · get_code("cfc17707f35e7ec4")
How it ran

The body of this sample is withheld: GitHub detected no licence in this paper's repository, cychungg/hairfusion when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

imread Ran
ran, honoured the contract we drafted
cychungg/hairfusion/dataset.py
pointer only (licence: NONE) · get_code("f4d6a41b4e50d0cb")
How it ran

The body of this sample is withheld: GitHub detected no licence in this paper's repository, cychungg/hairfusion when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

imread_for_albu Ran
ran, honoured the contract we drafted
cychungg/hairfusion/dataset.py
pointer only (licence: NONE) · get_code("f6ab4b62b58c4b25")
How it ran

The body of this sample is withheld: GitHub detected no licence in this paper's repository, cychungg/hairfusion when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

spatial_average Ran
ran; our contract draft was wrong, not the code
cychungg/hairfusion/eval_models/networks_basic.py
pointer only (licence: NONE) · get_code("29e5e72bcd006dcd")
How it ran

The body of this sample is withheld: GitHub detected no licence in this paper's repository, cychungg/hairfusion when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

upsample Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
cychungg/hairfusion/eval_models/networks_basic.py
pointer only (licence: NONE) · get_code("351677a36e1961df")
How it ran

The body of this sample is withheld: GitHub detected no licence in this paper's repository, cychungg/hairfusion when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

load_state_dict Not yet run
unverified (harvested, no recorded run)
cychungg/hairfusion/cldm/model.py
pointer only (licence: NONE) · get_code("35ad646f5b9e8cbf")
How it ran

The body of this sample is withheld: GitHub detected no licence in this paper's repository, cychungg/hairfusion when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. No invocation recorded.

score_2afc_dataset Not yet run
unverified (harvested, no recorded run)
cychungg/hairfusion/eval_models/dist_model.py
pointer only (licence: NONE) · get_code("dfd2379e29a03aef")
How it ran

The body of this sample is withheld: GitHub detected no licence in this paper's repository, cychungg/hairfusion when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. No invocation recorded.

Also present in other papers' code

Of 9 samples lifted from this paper's linked repositories, 9 carry a function identity and 0 do not. Of the 9 distinct functions with an identity, 5 are also present in other papers whose code we hold (5 with at least one paper dated earlier, 0 the same month, 3 later) and 4 are only here among the 52,977 papers whose code Syntology holds (as of 2026-09-26).

Only here means: among the 52,977 papers whose code Syntology holds (51,887 with lifted samples, 1,090 through their assemblies only), as of 2026-09-26, no other paper's lifted samples or current assembly bricks contain an identical function body after normalisation.

FunctionAlso present inEarliest-datedOthers named
get_state_dict 29 other papers
21 dated earlier, 7 later, 1 same year, order not determinable
2304.04269 (2023-04)
HumanSD: A Native Skeleton-Guided Diffusion Model for Human Image Generation
2305.02034 (2023-05)
SAMRS: Scaling-up Remote Sensing Segmentation Dataset with Segment Anything Model
2305.11147 (2023-05)
UniControl: A Unified Diffusion Model for Controllable Visual Generation In the Wild
and 26 more not named here
spatial_average 19 other papers
16 dated earlier, 2 later, 1 same year, order not determinable
1801.03924 (2018-01)
The Unreasonable Effectiveness of Deep Features as a Perceptual Metric
1912.04958 (2019-12)
Analyzing and Improving the Image Quality of StyleGAN
2002.09219 (2020-02)
Stochastic Latent Residual Video Prediction
and 16 more not named here
score_2afc_dataset 15 other papers
12 dated earlier, 2 later, 1 same year, order not determinable
1912.04958 (2019-12)
Analyzing and Improving the Image Quality of StyleGAN
2002.09219 (2020-02)
Stochastic Latent Residual Video Prediction
2005.00953 (2020-05)
Deep Generative Adversarial Residual Convolutional Networks for Real-World Super-Resolution
and 12 more not named here
upsample 10 other papers
9 dated earlier, 1 same year, order not determinable
1912.04958 (2019-12)
Analyzing and Improving the Image Quality of StyleGAN
2002.09219 (2020-02)
Stochastic Latent Residual Video Prediction
2005.05999 (2020-05)
Fast Deep Multi-patch Hierarchical Network for Nonhomogeneous Image Dehazing
and 7 more not named here
load_state_dict 1 other paper
1 dated earlier
2312.01725 (2023-12)
StableVITON: Learning Semantic Correspondence with Latent Diffusion Model for Virtual Try-On

Presence, not direction: an identical function body in two papers' repositories does not say who wrote it, which came from which, or that either paper's method rests on it. Matching is exact after normalisation, so a renamed or edited function is not matched. Dates are when papers appeared, not when code was written. Only .py files the harvester lifted are covered; notebooks are not read. A new-style arXiv id YYMM.NNNN dates a paper to the month 20YY-MM; otherwise Paper.year dates it to the year; otherwise it is undated. Dates are when the paper appeared, not when the code was written. Read 2026-11-22.

Repositories linked to this paper

Some links come from the archived Papers with Code dataset (CC BY-SA 4.0): attribution and licence.

Abstract

Hairstyle transfer is a challenging task in the image editing field that modifies the hairstyle of a given face image while preserving its other appearance and background features. The existing hairstyle transfer approaches heavily rely on StyleGAN, which is pre-trained on cropped and aligned face images. Hence, they struggle to generalize under challenging conditions such as extreme variations of head poses or focal lengths. To address this issue, we propose a one-stage hairstyle transfer diffusion model, HairFusion, that applies to real-world scenarios. Specifically, we carefully design a hair-agnostic representation as the input of the model, where the original hair information is thoroughly eliminated. Next, we introduce a hair align cross-attention (Align-CA) to accurately align the reference hairstyle with the face image while considering the difference in their head poses. To enhance the preservation of the face image's original features, we leverage adaptive hair blending during the inference, where the output's hair regions are estimated by the cross-attention map in Align-CA and blended with non-hair areas of the face image. Our experimental results show that our method achieves state-of-the-art performance compared to the existing methods in preserving the integrity of both the transferred hairstyle and the surrounding features. The codes are available at https://github.com/cychungg/HairFusion

For agents

The same record, over MCP at https://syntology.ai/mcp:

get_harvested_code_for_paper("2408.16450")
get_code_for_paper("2408.16450")
have("2408.16450")

The run record, dated, one paper per request, free:

curl https://syntology.ai/api/ran/2408.16450.json

A badge for a README (the split and the date, never a ratio):

[![Syntology run record](https://syntology.ai/api/ran/2408.16450.svg)](https://syntology.ai/paper/2408.16450)

Connect an agent — have() is free.