YOLOX icon indicating copy to clipboard operation
YOLOX copied to clipboard

mlflow logging integration with yolox training

Open Im-Himanshu opened this issue 1 year ago • 5 comments

Needed integration of yolox to log experiments with mlflow, the pull request provide additional option in -l --logger argument to log output in "mlflow".

Requires an environment file (.env) in the root folder of the projects.

required additional dependency of mlflow and python-dotenv failing which error is raised if logger is set to mlflow.

Im-Himanshu avatar May 15 '24 10:05 Im-Himanshu

Tested the logging on to data bricks, following logs are available for all the runs.

Logged params

image

logged metrices

image

logged artifacts

image

Im-Himanshu avatar May 15 '24 11:05 Im-Himanshu

@FateScript Requesting you to please review the pull request.

Im-Himanshu avatar May 15 '24 11:05 Im-Himanshu

Any update? @Im-Himanshu

FateScript avatar May 23 '24 12:05 FateScript

Any update? @Im-Himanshu

@FateScript Excuse me for the delayed response, I have pushed new commits to implement all the suggestions. Kindly review.

Im-Himanshu avatar Jun 17 '24 13:06 Im-Himanshu

Any update? @Im-Himanshu

@FateScript Excuse me for the delayed response, I have pushed new commits to implement all the suggestions. Kindly review.

@FateScript Gentle Reminder to Please check and merge the request.

Im-Himanshu avatar Jun 28 '24 17:06 Im-Himanshu

@Im-Himanshu Also please don't forget to lint your code.

FateScript avatar Jul 04 '24 11:07 FateScript

@Im-Himanshu Also please don't forget to lint your code.

Linted the code, the only major issue in lint, is the import statement which has to be done inside class (same as being done in wandb logger) because this is an optional feature. image

Im-Himanshu avatar Jul 04 '24 14:07 Im-Himanshu

@FateScript @Cloudhax23 completed all the suggestion, please check.

Im-Himanshu avatar Jul 04 '24 14:07 Im-Himanshu

@FateScript Removed the additional logger and linted the code again to remove build process error.

Im-Himanshu avatar Jul 05 '24 10:07 Im-Himanshu

@Im-Himanshu please isort your code(isort -rc), see here for more details.

FateScript avatar Jul 07 '24 10:07 FateScript

@Im-Himanshu please isort your code(isort -rc), see here for more details.

@FateScript in trainer.py and mlflow_logger.py, isort has transferred the import datetime and other default python package import at the end but it was not the case in original code so as of now I have manually shifted them to the top, please see if it is correct or not.

I think my isort setting are not matched to the project setting, if there are any settings of isort that I can follow for this project, I can rerun the isort or otherwise the sort that I have done now should be correct based on my intuition.

Im-Himanshu avatar Jul 08 '24 10:07 Im-Himanshu

@Im-Himanshu please isort your code(isort -rc), see here for more details.

@FateScript in trainer.py and mlflow_logger.py, isort has transferred the import datetime and other default python package import at the end but it was not the case in original code so as of now I have manually shifted them to the top, please see if it is correct or not.

I think my isort setting are not matched to the project setting, if there are any settings of isort that I can follow for this project, I can rerun the isort or otherwise the sort that I have done now should be correct based on my intuition.

If you instal the correct isort version(4.3.21 here), everything will be ok. BTW, be sure of the format check here passed before you commit.

FateScript avatar Jul 09 '24 03:07 FateScript

@Im-Himanshu please isort your code(isort -rc), see here for more details.

@FateScript in trainer.py and mlflow_logger.py, isort has transferred the import datetime and other default python package import at the end but it was not the case in original code so as of now I have manually shifted them to the top, please see if it is correct or not. I think my isort setting are not matched to the project setting, if there are any settings of isort that I can follow for this project, I can rerun the isort or otherwise the sort that I have done now should be correct based on my intuition.

If you instal the correct isort version(4.3.21 here), everything will be ok. BTW, be sure of the format check here passed before you commit.

@FateScript My isort version was not as required by the library, hence the previous errors. Anyway I have removed the given pylint and isort errors. It should pass all the checks this time.

Im-Himanshu avatar Jul 10 '24 04:07 Im-Himanshu

LGTM.

FateScript avatar Jul 11 '24 04:07 FateScript