Skip to content
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

AttributeError: module 'ray.train._internal.session' has no attribute '_get_session'. Did you mean: 'get_session'? #50828

Open
chbanti opened this issue Feb 22, 2025 · 0 comments
Labels
docs An issue or change related to documentation triage Needs triage (eg: priority, bug/not-bug, and owning component)

Comments

@chbanti
Copy link

chbanti commented Feb 22, 2025

Description

my yolov8 code and please guide me remove this error this in file "
%cd {HOME}

!yolo task=detect mode=train model=yolov8n.pt data={dataset.location}/data.yaml epochs=300 imgsz=800 plots=True optimizer=SGD
"
"Transferred 319/355 items from pretrained weights
TensorBoard: Start with 'tensorboard --logdir runs/detect/train4', view at http://localhost:6006/
Freezing layer 'model.22.dfl.conv.weight'
AMP: running Automatic Mixed Precision (AMP) checks with YOLOv8n...
AMP: checks passed ✅
train: Scanning /kaggle/working/datasets/trash-7/train/labels... 15542 images, 1
train: WARNING ⚠️ /kaggle/working/datasets/trash-7/train/images/Image_37-tb_jpg.rf.65960ae2620cd36e8252a1a7a716c532.jpg: 1 duplicate labels removed
train: WARNING ⚠️ /kaggle/working/datasets/trash-7/train/images/Image_37-tb_jpg.rf.e7635cedeae5b2eddd8a59b68ebc3074.jpg: 1 duplicate labels removed
train: WARNING ⚠️ /kaggle/working/datasets/trash-7/train/images/papernotb10_icstone7_jpg.rf.3c09de89f5c4a09067da86124af1164b.jpg: 1 duplicate labels removed
train: WARNING ⚠️ /kaggle/working/datasets/trash-7/train/images/papernotb10_icstone7_jpg.rf.e83017b01af94e1432cddc40c76192c1.jpg: 1 duplicate labels removed
train: New cache created: /kaggle/working/datasets/trash-7/train/labels.cache
/usr/local/lib/python3.10/dist-packages/albumentations/init.py:24: UserWarning: A new version of Albumentations is available: 2.0.4 (you have 1.4.20). Upgrade using: pip install -U albumentations. To disable automatic update checks, set the environment variable NO_ALBUMENTATIONS_UPDATE to 1.
check_for_updates()
albumentations: Blur(p=0.01, blur_limit=(3, 7)), MedianBlur(p=0.01, blur_limit=(3, 7)), ToGray(p=0.01, num_output_channels=3, method='weighted_average'), CLAHE(p=0.01, clip_limit=(1.0, 4.0), tile_grid_size=(8, 8))
val: Scanning /kaggle/working/datasets/trash-7/valid/labels... 934 images, 0 bac
val: New cache created: /kaggle/working/datasets/trash-7/valid/labels.cache
Plotting labels to runs/detect/train4/labels.jpg...
optimizer: SGD(lr=0.01, momentum=0.937) with parameter groups 57 weight(decay=0.0), 64 weight(decay=0.0005), 63 bias(decay=0.0)
TensorBoard: model graph visualization added ✅
Image sizes 800 train, 800 val
Using 2 dataloader workers
Logging results to runs/detect/train4
Starting training for 300 epochs...

  Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
  1/300      5.16G     0.7431      2.971       1.21         29        800: 1
             Class     Images  Instances      Box(P          R      mAP50  m
               all        934       2592      0.368      0.302      0.277       0.19

Traceback (most recent call last):
File "/usr/local/bin/yolo", line 8, in
sys.exit(entrypoint())
File "/usr/local/lib/python3.10/dist-packages/ultralytics/cfg/init.py", line 831, in entrypoint
getattr(model, mode)(**overrides) # default args from model
File "/usr/local/lib/python3.10/dist-packages/ultralytics/engine/model.py", line 803, in train
self.trainer.train()
File "/usr/local/lib/python3.10/dist-packages/ultralytics/engine/trainer.py", line 207, in train
self._do_train(world_size)
File "/usr/local/lib/python3.10/dist-packages/ultralytics/engine/trainer.py", line 458, in _do_train
self.run_callbacks("on_fit_epoch_end")
File "/usr/local/lib/python3.10/dist-packages/ultralytics/engine/trainer.py", line 168, in run_callbacks
callback(self)
File "/usr/local/lib/python3.10/dist-packages/ultralytics/utils/callbacks/raytune.py", line 17, in on_fit_epoch_end
if ray.train._internal.session._get_session(): # replacement for deprecated ray.tune.is_session_enabled()
AttributeError: module 'ray.train._internal.session' has no attribute '_get_session'. Did you mean: 'get_session'?
Sentry is attempting to send 1 pending events"
please guide me solve this error problem and isssue i try many different library but cannot resolve this issue

Link

No response

@chbanti chbanti added docs An issue or change related to documentation triage Needs triage (eg: priority, bug/not-bug, and owning component) labels Feb 22, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs An issue or change related to documentation triage Needs triage (eg: priority, bug/not-bug, and owning component)
Projects
None yet
Development

No branches or pull requests

1 participant