-
Notifications
You must be signed in to change notification settings - Fork 1
Init weights #46
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 our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Init weights #46
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A few WIP comments left.
The new parameter in the config files should be described in the readme of the repo.
## Get the config file of parameters to a execute a given task with a deep learning framework. Can be used to generate the default parameter value | ||
# cfg.merge_from_file(model_zoo.get_config_file(MODEL_ZOO_CHECKPOINT_URL)) | ||
# print(cfg) | ||
# sys.exit(1) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These lines should be deleted or implemented.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this one can be deleted.
@@ -127,8 +132,19 @@ def main(cfg_file_path): | |||
cfg.SOLVER.MAX_ITER = 500 | |||
|
|||
# ---- do training | |||
cfg.MODEL.WEIGHTS = model_zoo.get_checkpoint_url(MODEL_ZOO_CHECKPOINT_URL) | |||
if INIT_MODEL_WEIGHTS: | |||
# A common error that might occur is that the lr is too high: https://trello.com/c/BY4HtY9h#comment-673616d755b046983033e24f |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it relevant to keep a trello ref here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've added this comment for you to know, but if you want to publish it, it should be deleted.
if INIT_MODEL_WEIGHTS: | ||
# A common error that might occur is that the lr is too high: https://trello.com/c/BY4HtY9h#comment-673616d755b046983033e24f | ||
cfg.MODEL.WEIGHTS = "" | ||
logger.info("The weights of the pre-trained model are reinitialize. Training from scratch.") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"reinitialized" with d
## Visualize model parameters | ||
# print(len(list(trainer.model.parameters()))) | ||
# for p in trainer.model.parameters(): | ||
# print(p) | ||
# sys.exit(0) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These lines should be deleted or implemented.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
May be this one can be implemented as an option.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do you want me to make the change here? Or do you?
Anyway, I'd like to modify the post-processing script for the quarry example to make it consistent with the proj-dqry. So I can make the change directly in this branch if it's easier.
@@ -127,8 +132,19 @@ def main(cfg_file_path): | |||
cfg.SOLVER.MAX_ITER = 500 | |||
|
|||
# ---- do training | |||
cfg.MODEL.WEIGHTS = model_zoo.get_checkpoint_url(MODEL_ZOO_CHECKPOINT_URL) | |||
if INIT_MODEL_WEIGHTS: | |||
# A common error that might occur is that the lr is too high: https://trello.com/c/BY4HtY9h#comment-673616d755b046983033e24f |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've added this comment for you to know, but if you want to publish it, it should be deleted.
## Get the config file of parameters to a execute a given task with a deep learning framework. Can be used to generate the default parameter value | ||
# cfg.merge_from_file(model_zoo.get_config_file(MODEL_ZOO_CHECKPOINT_URL)) | ||
# print(cfg) | ||
# sys.exit(1) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this one can be deleted.
## Visualize model parameters | ||
# print(len(list(trainer.model.parameters()))) | ||
# for p in trainer.model.parameters(): | ||
# print(p) | ||
# sys.exit(0) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
May be this one can be implemented as an option.
No description provided.