SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 1904.10620 · 2019

Bidirectional Learning for Domain Adaptation of Semantic Segmentation

arXiv · PDF · Open in the Atlas

Code that ran

6 of 8 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; 1 honoured the contract we drafted, 0 violated it and 3 have no contract verdict; 2 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/1904.10620.json · badge: /api/ran/1904.10620.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
liyunsheng13/BDL canonical (classifier label)
classifier basis: census
6 ran · 2 no recorded run
FunctionStatusWhere it lives
Deeplab Ran
ran on a synthesized input
liyunsheng13/BDL/cyclegan/deeplab.py
code served (permissive licence) · get_code("ce5003e390b20787")
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 ResNet101. 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 as nn

torch.manual_seed(0)

ARGS = {
    'num_classes': 21,
    'init_weights': None,
    'restore_from': None,
    'phase': 'train',
}
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 ResNet101 — a ResNet101 output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a ResNet101 output the recorded ndim 0 and dtype family float 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
conv3x3 Ran
ran; our contract draft was wrong, not the code
liyunsheng13/BDL/model/deeplab.py
pointer only (licence: MIT); the stored copy get_code serves, from lixiaotong97/DSU, is pointer only (licence: NONE) · get_code("fac5364e2f53c6db")
How it ran

The body of this sample is withheld: this paper's link allows the body inline (MIT), but get_code serves the stored copy, first harvested from lixiaotong97/DSU, and GitHub detected no licence in that repository 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_norm_layer Ran
ran on a synthesized input
liyunsheng13/BDL/cyclegan/networks.py
code served (permissive licence) · get_code("8da796d8d2d055b4")
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 partial. 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 as nn
import functools

torch.manual_seed(0)

# The function get_norm_layer takes one parameter: norm_type
# It accepts 'batch', 'instance', or 'none' as valid values
# Let's test with 'instance' as a representative case

ARGS = {
    'norm_type': 'instance'
}
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 partial — a partial output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a partial output the recorded ndim 0 and dtype family float 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
get_scheduler Ran
ran on a synthesized input
liyunsheng13/BDL/cyclegan/networks.py
code served (permissive licence) · get_code("f4ecb472fd266452")
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 LambdaLR. 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 as nn
from torch.optim import Adam

torch.manual_seed(0)

# Create a simple model
model = nn.Linear(4, 3)

# Create an optimizer
optimizer = Adam(model.parameters(), lr=0.001)

# Create a config object with all required attributes
class OptConfig:
    def __init__(self):
        self.lr_policy = 'lambda'
        self.epoch_count = 0
        self.niter = 100
        self.niter_decay = 100
        self.lr_decay_iters = 10

opt = OptConfig()

ARGS = {
    'optimizer': optimizer,
    'opt': opt
}
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 LambdaLR — a LambdaLR output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a LambdaLR output the recorded ndim 0 and dtype family float 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
init_net Ran
ran; our contract draft was wrong, not the code
liyunsheng13/BDL/cyclegan/networks.py
pointer only (licence: MIT); the stored copy get_code serves, from LiangSiyuan21/Adversarial-Attacks-for-Image-and-Video-Object-Detection, is pointer only (licence: NONE) · get_code("10fdae626d954364")
How it ran

The body of this sample is withheld: this paper's link allows the body inline (MIT), but get_code serves the stored copy, first harvested from LiangSiyuan21/Adversarial-Attacks-for-Image-and-Video-Object-Detection, and GitHub detected no licence in that repository 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.

outS Ran
ran, honoured the contract we drafted
liyunsheng13/BDL/model/deeplab.py
pointer only (licence: MIT); the stored copy get_code serves, from stu92054/Domain-adaptation-on-segmentation, is pointer only (licence: NONE) · get_code("27504cbeb5811ea6")
How it ran

The body of this sample is withheld: this paper's link allows the body inline (MIT), but get_code serves the stored copy, first harvested from stu92054/Domain-adaptation-on-segmentation, and GitHub detected no licence in that repository 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.

Deeplab Not yet run
unverified (harvested, no recorded run)
liyunsheng13/BDL/model/deeplab.py
code served (permissive licence) · get_code("bfb91dad724d81b9")
How it ran

no invocation recorded.

VGG16_FCN8s Not yet run
unverified (harvested, no recorded run)
liyunsheng13/BDL/model/fcn8s.py
code served (permissive licence) · get_code("ce027ad71394d243")
How it ran

no invocation recorded.

Also present in other papers' code

Of 8 samples lifted from this paper's linked repositories, 8 carry a function identity and 0 do not. Of the 8 distinct functions with an identity, 6 are also present in other papers whose code we hold (5 with at least one paper dated earlier, 2 the same month, 6 later) and 2 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
conv3x3 686 other papers
102 dated earlier, 16 the same month, 568 later · 31 only as an assembly brick
1406.2661 (2014-06)
Generative Adversarial Networks
1409.0575 (2014-09)
ImageNet Large Scale Visual Recognition Challenge
1412.6572 (2014-12)
Explaining and Harnessing Adversarial Examples
and 683 more not named here
outS 11 other papers
5 dated earlier, 6 later
1612.02646 (2016-12)
Learning Video Object Segmentation from Static Images
1802.10349 (2018-02)
Learning to Adapt Structured Output Space for Semantic Segmentation
1809.09478 (2018-09)
Taking A Closer Look at Domain Shift: Category-level Adversaries for Semantics Consistent Domain Adaptation
and 8 more not named here
init_net 5 other papers
4 dated earlier, 1 later
1611.07004 (2016-11)
Image-to-Image Translation with Conditional Adversarial Networks
1804.07723 (2018-04)
Image Inpainting for Irregular Holes Using Partial Convolutions
1807.09251 (2018-07)
GANimation: Anatomically-aware Facial Animation from a Single Image
and 2 more not named here
get_norm_layer 4 other papers
3 dated earlier, 1 later
1406.2283 (2014-06)
Depth Map Prediction from a Single Image using a Multi-Scale Deep Network
1611.07004 (2016-11)
Image-to-Image Translation with Conditional Adversarial Networks
1901.08954 (2019-01)
Skip-GANomaly: Skip Connected and Adversarially Trained Encoder-Decoder Anomaly Detection
and 1 more not named here
get_scheduler 4 other papers
2 dated earlier, 1 the same month, 1 later
1611.07004 (2016-11)
Image-to-Image Translation with Conditional Adversarial Networks
1807.09251 (2018-07)
GANimation: Anatomically-aware Facial Animation from a Single Image
1904.03349 (2019-04)
Progressive Pose Attention Transfer for Person Image Generation
and 1 more not named here
Deeplab 1 other paper
1 later
2003.08440 (2020-03)
Synthesize then Compare: Detecting Failures and Anomalies for Semantic Segmentation

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

Domain adaptation for semantic image segmentation is very necessary since manually labeling large datasets with pixel-level labels is expensive and time consuming. Existing domain adaptation techniques either work on limited datasets, or yield not so good performance compared with supervised learning. In this paper, we propose a novel bidirectional learning framework for domain adaptation of segmentation. Using the bidirectional learning, the image translation model and the segmentation adaptation model can be learned alternatively and promote to each other. Furthermore, we propose a self-supervised learning algorithm to learn a better segmentation adaptation model and in return improve the image translation model. Experiments show that our method is superior to the state-of-the-art methods in domain adaptation of segmentation with a big margin. The source code is available at https://github.com/liyunsheng13/BDL.

For agents

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

get_harvested_code_for_paper("1904.10620")
get_code_for_paper("1904.10620")
have("1904.10620")

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

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

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

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

Connect an agent — have() is free.