Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Personalised FedReID#10

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Open
codergan wants to merge74 commits intocap-ntu:master
base:master
Choose a base branch
Loading
fromcodergan:master
Open

Conversation

@codergan
Copy link
Collaborator

support personalised clustering training for FedReID

gan xinand others added28 commitsJanuary 22, 2021 15:53
# inputs = Variable(inputs.cuda().detach())
# labels = Variable(labels.cuda().detach())
#else:
# inputs, labels = Variable(inputs), Variable(labels)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

Can just remove these comments

self.model.train(True)
optimizer=get_optimizer(self.model,self.lr)
scheduler=lr_scheduler.StepLR(optimizer,step_size=40,gamma=0.1)
#scheduler = lr_scheduler.StepLR(optimizer, step_size=40, gamma=0.1)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

Why we don't need the scheduler anymore?

#parser = argparse.ArgumentParser(description='Training')
#parser.add_argument('--result_dir', default='.', type=str)
#parser.add_argument('--dataset', default='no_dataset', type=str)
#args = parser.parse_args()
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

Remove these comments

gallery_label=np.array(result['gallery_label'])
# print(type(query_feature),query_feature[:3])
# print(type(query_cam),query_cam[:3])
# print(type(query_label),query_label[:3])
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

Remove these debugging prints

# result = scipy.io.loadmat(file_path)
# print("========= after loading ==========")
# for i in result:
# print(i, np.array(result[i]).shape)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

Remove these comments

ifargs.regularization:
reg="reg"
else:
reg="Nreg"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

Are theseif else from line 95 - 110 only for setting the name for the checkpoint? It would be better to put them into a function.

parser.add_argument('--multiple_scale',default='1',type=str,help='multiple_scale: e.g. 1 1,1.1 1,1.1,1.2')
parser.add_argument('--test_dir',default='all',type=str,help='./test_data')

parser.add_argument('--resume_epoch',default=0,type=int,help='resume from which epoch, if 0, no resume')
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

Shouldn't it be resume round?

@@ -0,0 +1,4 @@
export PYTHONPATH=$PYTHONPATH:$pwd
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

Put all these scripts for running into a separate folderscript

importrandom
importtorch.optimasoptim
fromtorchvisionimportdatasets
# from finch import FINCH
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

remove comment


print("==============================")
print("number of clients used:",len(models))
#print("number of clients used:", len(models))
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

Remove comment

Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

@weimingwillweimingwillweimingwill requested changes

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

2 participants

@codergan@weimingwill

[8]ページ先頭

©2009-2025 Movatter.jp