-What is the top-level directory of the model:
GPU-Server1:~/domain_adaptaion$ ls
datasets domain_separation __init__.py README.md WORKSPACE
I'm facing this issue-
When running
bazel build -c opt domain_separation/...
I get this error:
ERROR: /home/jaytest/domain_adaptaion/domain_separation/BUILD:103:1: no such package 'domain_adaptation/datasets': BUILD file not found on package path and referenced by '//domain_separation:models_test'.
ERROR: Analysis of target '//domain_separation:models_test' failed; build aborted.
INFO: Elapsed time: 0.983s
And I run again
bazel build -c opt domain_separation/...
I get another error:
ERROR: /home/jaytest/domain_adaptaion/domain_separation/BUILD:79:1: no such package 'domain_adaptation/datasets': BUILD file not found on package path and referenced by '//domain_separation:dsn_train'.
ERROR: Analysis of target '//domain_separation:dsn_train' failed; build aborted.
INFO: Elapsed time: 0.096s
I already checked these files are under the "domain_separation" folder
Can you please help me how to resolve it?
Cc @bousmalis.
Hi, you will need to build from the parent directory (models) that includes the slim and domain_adaptation directories. From there you can follow the instructions: https://github.com/tensorflow/models/tree/master/domain_adaptation
Also note that both models and models/slim need to be added to your $PYTHONPATH. Please, let me know if there are any more issues.
@bousmalis If the bazel command depends on the working directory in which it is executed, that's seems like a bug that should be fixed.
Thanks for your help.
I can run it without error now.
But, I have another problem.
I follow instruction in slim and get mnist_train.tfrecord file.
Then, I modify the downloading and converting code in slim and get mnist_m_train.tfrecord file.
And I apply DSN on these two dataset by following command
./bazel-bin/domain_adaptation/domain_separation/dsn_train --similarity_loss=dann_loss --basic_tower=dann_mnist --source_dataset=mnist --target_dataset=mnist_m --learning_rate=0.0117249 --alpha_weight=0.01 --beta_weight=0.05 --gamma_weight=0.251175 --weight_decay=1e-6 --max_number_of_steps=60000 --layers_to_regularize=fc3 --use_separation=True --master="" --dataset_dir=/home/jaytest/models/domain_adaptation/datasets -v --use_logging --train_log_dir=/home/jaytest/models/domain_adaptation/tmp/da
I can only get test accuracy about 72% in mnist_m.
Is there any hyperparameter that i didn't set up correctly?
@JJTasi I am having the same problem here. Test accuracy is around 0.72. Have you further investigated this issue?
I run the command bazel build -c opt domain_adaptation/domain_separation/... at research directory, this directory is the parent directory of slim and domain_adaptation. But I still have the error no such package 'domain_adaptation/datasets'. I clone the master branch of this repo, how can I solve this problem?
@bousmalis can you comment?
Same problem here. Is there a solution for it?
Hello,everyone,I also come across the same question.Running the command bazel build -c opt domain_adaptation/domain_separation/... at research directory, this directory is the parent directory of slim and domain_adaptation. But there still have the error no such package 'domain_adaptation/datasets'.
Can anyone please help me how to resolve it?
I reproduced a simplified version of DSN, you can check it here https://github.com/AmirHussein96/Simplified-DSN
OK~wonderful!Really thank you for your code and your reply~
------------------ Original ------------------
From: Amir Hussein <[email protected]>
Date: Thu,Oct 31,2019 4:39 AM
To: tensorflow/models <[email protected]>
Cc: 475000327 <[email protected]>, Comment <[email protected]>
Subject: Re: [tensorflow/models] [domain adaptation] no such package 'domain_adaptation/datasets' (#1396)
I reproduced a simplified version of DSN, you can check it here https://github.com/AmirHussein96/Simplified-DSN
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub, or unsubscribe.
@bousmalis @dmrd Can you add the link of AmirHussein96's repo to the README.md file so that TF community can find an unofficial version easily?
Added the link of AmirHussein96's repo to the README.md file.
https://github.com/tensorflow/models/blob/master/research/domain_adaptation/README.md#other-implementations
@AmirHussein96 Thank you for your contribution.
Most helpful comment
Thanks for your help.
I can run it without error now.
But, I have another problem.
I follow instruction in slim and get mnist_train.tfrecord file.
Then, I modify the downloading and converting code in slim and get mnist_m_train.tfrecord file.
And I apply DSN on these two dataset by following command
./bazel-bin/domain_adaptation/domain_separation/dsn_train --similarity_loss=dann_loss --basic_tower=dann_mnist --source_dataset=mnist --target_dataset=mnist_m --learning_rate=0.0117249 --alpha_weight=0.01 --beta_weight=0.05 --gamma_weight=0.251175 --weight_decay=1e-6 --max_number_of_steps=60000 --layers_to_regularize=fc3 --use_separation=True --master="" --dataset_dir=/home/jaytest/models/domain_adaptation/datasets -v --use_logging --train_log_dir=/home/jaytest/models/domain_adaptation/tmp/daI can only get test accuracy about 72% in mnist_m.
Is there any hyperparameter that i didn't set up correctly?