-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
189 changed files
with
7,070 additions
and
2,207 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
# Sphinx build info version 1 | ||
# This file hashes the configuration used when building these files. When it is not found, a full rebuild will be done. | ||
config: 48d0245515a1ca80bc37c0931e40c20f | ||
config: 84bc96467903e48216c9956d05985a38 | ||
tags: 645f666f9bcd5a90fca523b33c5a78b7 |
11 changes: 11 additions & 0 deletions
11
docs/build/html/_downloads/79dff157bfbc0773edb46ea14b42e885/demo_config_single_run_diva.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
--- # yaml demo document | ||
|
||
te_d: caltech | ||
tpath: examples/tasks/task_vlcs.py | ||
bs: 2 | ||
model: diva | ||
debug: True | ||
gamma_y: 700000.0 #7e5 | ||
gamma_d: 100000.0 #1e5 | ||
nname: alexnet | ||
nname_dom: conv_bn_pool_2 |
61 changes: 61 additions & 0 deletions
61
docs/build/html/_downloads/adcf8c984b69173567c65fba4c00b880/task_vlcs.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
import os | ||
from torchvision import transforms | ||
from domainlab.tasks.task_folder_mk import mk_task_folder | ||
from domainlab.tasks.utils_task import ImSize | ||
|
||
# relative path is essential here since this file is used for testing, no absolute directory possible | ||
|
||
path_this_file = os.path.dirname(os.path.realpath(__file__)) | ||
chain = mk_task_folder(extensions={"caltech": "jpg", "sun": | ||
"jpg", "labelme": "jpg"}, | ||
list_str_y=["chair", "car"], | ||
dict_domain_folder_name2class={ | ||
"caltech": {"auto": "car", "stuhl": "chair"}, | ||
"sun": {"vehicle": "car", "sofa": "chair"}, | ||
"labelme": {"drive": "car", "sit": "chair"} | ||
}, | ||
dict_domain_img_trans={ | ||
"caltech": transforms.Compose( | ||
[transforms.Resize((256, 256)), | ||
transforms.CenterCrop(224), | ||
transforms.ToTensor(), | ||
transforms.Normalize( | ||
[0.485, 0.456, 0.406], std=[0.229, 0.224, 0.225]) | ||
]), | ||
"sun": transforms.Compose( | ||
[transforms.Resize((256, 256)), | ||
transforms.CenterCrop(224), | ||
transforms.ToTensor(), | ||
transforms.Normalize( | ||
[0.485, 0.456, 0.406], std=[0.229, 0.224, 0.225]) | ||
]), | ||
"labelme": transforms.Compose( | ||
[transforms.Resize((256, 256)), | ||
transforms.CenterCrop(224), | ||
transforms.ToTensor(), | ||
transforms.Normalize( | ||
[0.485, 0.456, 0.406], std=[0.229, 0.224, 0.225]) | ||
]), | ||
}, | ||
img_trans_te=transforms.Compose( | ||
[transforms.Resize((256, 256)), | ||
transforms.CenterCrop(224), | ||
transforms.ToTensor(), | ||
transforms.Normalize( | ||
[0.485, 0.456, 0.406], std=[0.229, 0.224, 0.225])]), | ||
isize=ImSize(3, 224, 224), | ||
dict_domain2imgroot={ | ||
"caltech": os.path.join( | ||
path_this_file, | ||
"../../data/vlcs_mini/caltech/"), | ||
"sun": os.path.join( | ||
path_this_file, | ||
"../../data/vlcs_mini/sun/"), | ||
"labelme": os.path.join( | ||
path_this_file, | ||
"../../data/vlcs_mini/labelme/")}, | ||
taskna="e_mini_vlcs") | ||
|
||
|
||
def get_task(na=None): | ||
return chain |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.