SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2601.04520 · 2026

FaceRefiner: High-Fidelity Facial Texture Refinement with Differentiable Rendering-based Style Transfer

Jing Liao, Yao Cheng, Haocheng Zhang, Xuan Cheng, Chengyang Li, Renshuai Liu, Yinglin Zheng, Baoping Cheng

arXiv · PDF · Open in the Atlas

Code that ran

17 of 23 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; 15 failures of our instrument; 6 no recorded run), measured 2026-11-22; 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/2601.04520.json · badge: /api/ran/2601.04520.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
HarshWinterBytes/FaceRefiner community
Papers with Code archive
17 ran · 6 no recorded run
FunctionStatusWhere it lives
compute_rotation Ran
ran; our contract draft was wrong, not the code
HarshWinterBytes/FaceRefiner/style_transfer_3d.py
code served (permissive licence) · get_code("742789c5ea9f0aeb")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned Tensor, ndim 3, dtype family float, shape (2, 3, 3) as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch

torch.manual_seed(0)

# The function expects:
# - angles: a tensor of shape [batch_size, 3] containing rotation angles in radians
# - device: a torch device object

batch_size = 2
angles = torch.randn(batch_size, 3)
device = torch.device('cpu')

ARGS = {
    'angles': angles,
    'device': device
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Tensor, ndim 3, dtype family float, shape (2, 3, 3) — shape (2, 3, 3) as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
content_loss Ran
ran; our contract draft was wrong, not the code
HarshWinterBytes/FaceRefiner/style_transfer_3d.py
code served (permissive licence) · get_code("9048898fe4212b43")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned Tensor, ndim 0, dtype family float, shape () as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch

torch.manual_seed(0)

# Create small feature tensors
# feat_result: shape (batch, channels, height, width) or similar
# The function transposes and reshapes to (d, -1) then (N, d)
# Let's use shape (2, 4, 2, 2) - batch=2, channels=4, spatial=2x2
feat_result = torch.randn(2, 4, 2, 2)

# feat_content: same structure as feat_result
feat_content = torch.randn(2, 4, 2, 2)

ARGS = {
    "feat_result": feat_result,
    "feat_content": feat_content,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Tensor, ndim 0, dtype family float, shape () — shape () as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
convert_image Ran
ran; our contract draft was wrong, not the code
HarshWinterBytes/FaceRefiner/style_transfer_3d.py
code served (permissive licence) · get_code("e973fe11eef5feb2")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned ndarray, ndim 3, dtype family int, shape (3, 2, 4) as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch
import numpy as np

torch.manual_seed(0)

# The function expects a tensor x with shape (C, H, W)
# It calls .permute(1, 2, 0), .detach(), .cpu(), .numpy()
# So x should be a torch tensor with 3 dimensions

x = torch.randn(4, 3, 2)  # (C=4, H=3, W=2) - distinct sizes for each dimension

ARGS = {
    "x": x
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type ndarray, ndim 3, dtype family int, shape (3, 2, 4) — shape (3, 2, 4) as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
create_laplacian_pyramid Ran
ran; our contract draft was wrong, not the code
HarshWinterBytes/FaceRefiner/style_transfer_3d.py
code served (permissive licence) · get_code("3be40a64043dfdef")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned list. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch
import torch.nn.functional as F

torch.manual_seed(0)

# Create a small image tensor: batch_size=2, channels=4, height=8, width=6
image = torch.randn(2, 4, 8, 6)

# pyramid_depth determines how many levels to create
pyramid_depth = 2

ARGS = {
    "image": image,
    "pyramid_depth": pyramid_depth,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type list — a list output has no array shape of its own; none is stated
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
distmat Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
HarshWinterBytes/FaceRefiner/style_transfer_3d.py
code served (permissive licence) · get_code("b1b682ae87523be2")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned Tensor, ndim 2, dtype family float, shape (2, 3) as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch

torch.manual_seed(0)

# Create small tensors for x and y
# x: shape (2, 4) - 2 samples, 4 dimensions
# y: shape (3, 4) - 3 samples, 4 dimensions (distinct from x's batch size)
x = torch.randn(2, 4)
y = torch.randn(3, 4)

ARGS = {
    "x": x,
    "y": y,
    "cos_d": True
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Tensor, ndim 2, dtype family float, shape (2, 3) — shape (2, 3) as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
get_opp_pose Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
HarshWinterBytes/FaceRefiner/style_transfer_3d.py
code served (permissive licence) · get_code("507e4cbf06da27a0")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned Tensor, ndim 3, dtype family float, shape (2, 4, 3) as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch

torch.manual_seed(0)

# face_vertex: tensor with shape [batch_size, num_vertices, 3]
# The function accesses face_vertex[..., -1], face_vertex[..., 2]
# and performs matrix multiplication with rotation matrices (3x3)
# So last dimension must be 3
face_vertex = torch.randn(2, 4, 3)

# angle: tensor with shape [batch_size, 3]
# The function extracts angles[:, :1], angles[:, 1:2], angles[:, 2:]
# for x, y, z rotations
angle = torch.randn(2, 3)

# camera_d: scalar value used for z-coordinate transformation
camera_d = 10.0

# device: torch device (CPU only)
device = torch.device('cpu')

ARGS = {
    'face_vertex': face_vertex,
    'angle': angle,
    'camera_d': camera_d,
    'device': device
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Tensor, ndim 3, dtype family float, shape (2, 4, 3) — shape (2, 4, 3) as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
laplacian Ran
ran; our contract draft was wrong, not the code
HarshWinterBytes/FaceRefiner/style_transfer_3d.py
code served (permissive licence) · get_code("af0d1a80ada41635")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned Tensor, ndim 4, dtype family float, shape (2, 4, 8, 6) as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch
import torch.nn.functional as F

torch.manual_seed(0)

# The laplacian function takes a single parameter 'x' which is a tensor
# It performs interpolation operations on x, so x needs to be a 4D tensor
# (batch, channels, height, width) for F.interpolate to work

# Create a small 4D tensor: batch_size=2, channels=4, height=8, width=6
x = torch.randn(2, 4, 8, 6)

ARGS = {
    'x': x
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Tensor, ndim 4, dtype family float, shape (2, 4, 8, 6) — shape (2, 4, 8, 6) as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
moment_loss Ran
ran; our contract draft was wrong, not the code
HarshWinterBytes/FaceRefiner/style_transfer_3d.py
code served (permissive licence) · get_code("489fa752175246f1")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned Tensor, ndim 0, dtype family float, shape () as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch

torch.manual_seed(0)

# Create small tensors: batch_size=2, feature_dim=4
X = torch.randn(2, 4)
Y = torch.randn(2, 4)

# moments parameter: list of which moments to compute (1st moment and/or 2nd moment)
moments = [1, 2]

ARGS = {
    "X": X,
    "Y": Y,
    "moments": moments,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Tensor, ndim 0, dtype family float, shape () — shape () as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
pairwise_distances_cos Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
HarshWinterBytes/FaceRefiner/style_transfer_3d.py
code served (permissive licence) · get_code("ba1b0f91c73f3da9")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned Tensor, ndim 2, dtype family float, shape (2, 3) as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch

torch.manual_seed(0)

# Create two small tensors for x and y
# x: shape (2, 4) - 2 vectors of dimension 4
# y: shape (3, 4) - 3 vectors of dimension 4
x = torch.randn(2, 4)
y = torch.randn(3, 4)

ARGS = {
    "x": x,
    "y": y,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Tensor, ndim 2, dtype family float, shape (2, 3) — shape (2, 3) as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
pairwise_distances_sq_l2 Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
HarshWinterBytes/FaceRefiner/style_transfer_3d.py
code served (permissive licence) · get_code("88e0d1da54b7b822")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned Tensor, ndim 2, dtype family float, shape (2, 3) as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch

torch.manual_seed(0)

# Create two small 2D tensors with distinct dimensions
# x: (2, 4) - 2 samples, 4 dimensions
# y: (3, 4) - 3 samples, 4 dimensions
x = torch.randn(2, 4)
y = torch.randn(3, 4)

ARGS = {
    "x": x,
    "y": y,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Tensor, ndim 2, dtype family float, shape (2, 3) — shape (2, 3) as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
pil_loader Ran
ran, honoured the contract we drafted
HarshWinterBytes/FaceRefiner/style_transfer_3d.py
code served (permissive licence) · get_code("78ba96e17205fe58")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned Image. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import numpy as np
from PIL import Image
import tempfile
import os

# Create a temporary image file for testing
temp_dir = tempfile.mkdtemp()
temp_image_path = os.path.join(temp_dir, "test_image.png")

# Create a small RGB image with some pixels and some zeros (mask regions)
img_array = np.random.randint(0, 256, (8, 8, 3), dtype=np.uint8)
# Set some pixels to zero to create mask regions
img_array[0:2, 0:2] = 0
img = Image.fromarray(img_array, mode='RGB')
img.save(temp_image_path)

ARGS = {
    "path": temp_image_path,
    "flag": False
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
PIL, numpy, scipy — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Image — a Image output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a Image output the recorded ndim 3 and dtype family int describe that coercion, not the output, and are not stated
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
remd_loss Ran
ran; our contract draft was wrong, not the code
HarshWinterBytes/FaceRefiner/style_transfer_3d.py
code served (permissive licence) · get_code("d65a589034e3f7cc")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned tuple, ndim 1, dtype family float; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch

torch.manual_seed(0)

# Create small tensors for X and Y
# X and Y are used in remd_loss which expects shape (batch_size, feature_dim)
# The function will reshape them, so we need realistic dimensions
X = torch.randn(2, 4)  # batch_size=2, feature_dim=4
Y = torch.randn(3, 4)  # batch_size=3, feature_dim=4

ARGS = {
    'X': X,
    'Y': Y,
    'cos_d': True
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type tuple, ndim 1, dtype family float — a tuple output has no array shape of its own; none is stated
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
rgb_to_yuv Ran
ran; our contract draft was wrong, not the code
HarshWinterBytes/FaceRefiner/style_transfer_3d.py
code served (permissive licence) · get_code("f0b42ce5f88d7c1e")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned Tensor, ndim 2, dtype family float, shape (3, 4) as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch

torch.manual_seed(0)

# The function expects an rgb tensor
# Looking at the function body:
# - rgb is used with .device attribute (so it's a tensor)
# - rgb is passed to torch.mm(C, rgb), so C (3x3) is matrix-multiplied with rgb
# - This means rgb must be shape (3, N) where N is the number of color values
# - For a typical RGB image or batch, rgb would be (3, num_pixels) or (3, batch_size)

# Create a small RGB tensor of shape (3, 4) - 3 channels, 4 samples
rgb = torch.randn(3, 4)

ARGS = {
    "rgb": rgb
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Tensor, ndim 2, dtype family float, shape (3, 4) — shape (3, 4) as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
sample_indices Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
HarshWinterBytes/FaceRefiner/style_transfer_3d.py
code served (permissive licence) · get_code("60286242a5072d72")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned tuple, ndim 2, dtype family int; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import numpy as np
import torch

# feat_content is accessed for its shape attribute, specifically:
# feat_content.shape[2] and feat_content.shape[3]
# The function expects a 4D tensor-like object with shape (batch, channels, height, width)
feat_content = np.random.randn(2, 4, 16, 20)

ARGS = {
    "feat_content": feat_content
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type tuple, ndim 2, dtype family int — a tuple output has no array shape of its own; none is stated
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
sample_indices_by_mask Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
HarshWinterBytes/FaceRefiner/style_transfer_3d.py
code served (permissive licence) · get_code("f4d12621823c8513")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned tuple, ndim 2, dtype family int; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import numpy as np
import random

# Set seed for reproducibility
random.seed(0)
np.random.seed(0)

# Create a mask with shape (1, 1, height, width)
# The function accesses mask[0][0] and looks for values > 0
# argwhere returns coordinates where mask[0][0] > 0
# We need at least 2 rows (for xx, yy indexing with g[0] and g[1])

mask_data = np.array([[
    [
        [1, 0, 2, 0],
        [0, 3, 0, 4],
        [5, 0, 6, 0]
    ]
]])

# Verify the structure: mask_data[0][0] should be a 2D array
# argwhere will return coordinates of non-zero elements
# The result should have shape (num_nonzero, 2) where each row is [row_idx, col_idx]

ARGS = {
    "mask": mask_data
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type tuple, ndim 2, dtype family int — a tuple output has no array shape of its own; none is stated
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
synthetize_image_from_laplacian_pyramid Ran
ran, honoured the contract we drafted
HarshWinterBytes/FaceRefiner/style_transfer_3d.py
code served (permissive licence) · get_code("a837da06fde6272c")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned Tensor, ndim 4, dtype family float, shape (2, 4, 32, 32) as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch
import torch.nn.functional as F

torch.manual_seed(0)

# Build a laplacian pyramid as a list of tensors
# Each tensor should have size (batch, channels, height, width)
# We'll create a pyramid with decreasing spatial dimensions
laplacian_pyramid = [
    torch.randn(2, 4, 32, 32),  # Level 0: largest
    torch.randn(2, 4, 16, 16),  # Level 1
    torch.randn(2, 4, 8, 8),    # Level 2: smallest (base)
]

ARGS = {
    'laplacian_pyramid': laplacian_pyramid,
    'add_noise': False,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Tensor, ndim 4, dtype family float, shape (2, 4, 32, 32) — shape (2, 4, 32, 32) as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
tensor_resample Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
HarshWinterBytes/FaceRefiner/style_transfer_3d.py
code served (permissive licence) · get_code("1171d08b04aaf960")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned Tensor, ndim 4, dtype family float, shape (2, 3, 8, 10) as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch
import torch.nn.functional as F

torch.manual_seed(0)

# Create a small input tensor with shape (batch=2, channels=3, height=4, width=5)
# for 4D spatial interpolation (typical for images)
tensor = torch.randn(2, 3, 4, 5)

# Define destination size as a tuple (height, width)
dst_size = (8, 10)

# Define interpolation mode
mode = 'bilinear'

ARGS = {
    'tensor': tensor,
    'dst_size': dst_size,
    'mode': mode
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Tensor, ndim 4, dtype family float, shape (2, 3, 8, 10) — shape (2, 3, 8, 10) as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
fill_UV Not yet run
unverified (harvested, no recorded run)
HarshWinterBytes/FaceRefiner/style_transfer_3d.py
code served (permissive licence) · get_code("2a46d16bc5b985f0")
How it ran

no invocation recorded.

pil_resize_to_tensor Not yet run
unverified (harvested, no recorded run)
HarshWinterBytes/FaceRefiner/style_transfer_3d.py
code served (permissive licence) · get_code("cc73e4f799745329")
How it ran

no invocation recorded.

pil_to_tensor Not yet run
unverified (harvested, no recorded run)
HarshWinterBytes/FaceRefiner/style_transfer_3d.py
code served (permissive licence) · get_code("8a62e6ae5a393b69")
How it ran

no invocation recorded.

spatial_feature_extract Not yet run
unverified (harvested, no recorded run)
HarshWinterBytes/FaceRefiner/style_transfer_3d.py
code served (permissive licence) · get_code("ecf38fa102edb0c4")
How it ran

no invocation recorded.

style_transfer_3D Not yet run
unverified (harvested, no recorded run)
HarshWinterBytes/FaceRefiner/style_transfer_3d.py
code served (permissive licence) · get_code("25da328339455770")
How it ran

no invocation recorded.

tensor_erode Not yet run
unverified (harvested, no recorded run)
HarshWinterBytes/FaceRefiner/style_transfer_3d.py
code served (permissive licence) · get_code("a6bbeb1adb804b44")
How it ran

no invocation recorded.

Also present in other papers' code

Of 23 samples lifted from this paper's linked repositories, 23 carry a function identity and 0 do not. Of the 23 distinct functions with an identity, 0 are also present in other papers whose code we hold (0 with at least one paper dated earlier, 0 the same month, 0 later) and 23 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.

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

Recent facial texture generation methods prefer to use deep networks to synthesize image content and then fill in the UV map, thus generating a compelling full texture from a single image. Nevertheless, the synthesized texture UV map usually comes from a space constructed by the training data or the 2D face generator, which limits the methods' generalization ability for in-the-wild input images. Consequently, their facial details, structures and identity may not be consistent with the input. In this paper, we address this issue by proposing a style transferbased facial texture refinement method named FaceRefiner. FaceRefiner treats the 3D sampled texture as style and the output of a texture generation method as content. The photo-realistic style is then expected to be transferred from the style image to the content image. Different from current style transfer methods that only transfer high and middle level information to the result, our style transfer method integrates differentiable rendering to also transfer low level (or pixel level) information in the visible face regions. The main benefit of such multi-level information transfer is that, the details, structures and semantics in the input can thus be well preserved. The extensive experiments on Multi-PIE, CelebA and FFHQ datasets demonstrate that our refinement method can improve the texture quality and the face identity preserving ability, compared with state-of-the-arts. The code is available in https://github.com/HarshWinterBytes/FaceRefiner

For agents

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

get_harvested_code_for_paper("2601.04520")
get_code_for_paper("2601.04520")
have("2601.04520")

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

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

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

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

Connect an agent — have() is free.