Colab and Kaggle loggers removeHandler#8985
Merged
glenn-jocher merged 1 commit intomasterfrom Aug 16, 2022
Merged
Conversation
Resolve duplicate outputs in colab. Also optimizes Colab and Kaggle environment checks. Signed-off-by: Glenn Jocher <glenn.jocher@ultralytics.com>
ctjanuhowski
pushed a commit
to ctjanuhowski/yolov5
that referenced
this pull request
Sep 8, 2022
Resolve duplicate outputs in colab. Also optimizes Colab and Kaggle environment checks. Signed-off-by: Glenn Jocher <glenn.jocher@ultralytics.com> Signed-off-by: Glenn Jocher <glenn.jocher@ultralytics.com>
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Resolve duplicate outputs in colab. Also optimizes Colab and Kaggle environment checks.
Signed-off-by: Glenn Jocher glenn.jocher@ultralytics.com
🛠️ PR Summary
Made with ❤️ by Ultralytics Actions
🌟 Summary
Enhancements to environment detection and logging setup in the Ultralytics YOLOv5 codebase.
📊 Key Changes
is_asciifunction to check if a string contains only ASCII characters.is_colabfunction to detect Google Colab environment more reliably.set_loggingto handle Colab environment similarly to Kaggle.is_dockerfunction to a different location within the file for better code organization.is_kagglefunction to remove assertions and use a more direct return statement.is_ascii,is_docker, andis_colabdefinitions.🎯 Purpose & Impact
is_asciifunction might help in situations where non-ASCII characters could cause issues.is_colabfunction offers more precise detection, which could aid in configuring environments or troubleshooting.