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

sam2 training.py :omegaconf.errors.ConfigAttributeError: Key 'launcher' is not in struct #422

Open
darkstar1227 opened this issue Oct 29, 2024 · 0 comments

Comments

@darkstar1227
Copy link

I am trying to fine-tune the sam2 with my own custom data, but there is an issue I have met.

  • My system information:
GPU: A100 80G
pytorch:2.3.1(it will have a strange error, when pytorch >= 2.4, . I might open another issue.)
setup code: SAM2_BUILD_ALLOW_ERRORS=0 pip install --no-cache-dir -v -e ".[dev]"
  • Here is my dataset config:
dataset:
  # PATHS to Dataset
  img_folder: ./dataset/train/images # PATH to MOSE JPEGImages folder
  gt_folder: ./dataset/train/instances # PATH to MOSE Annotations folder
  file_list_txt: null # Optional PATH to filelist containing a subset of videos to be used for training
  • The error message:
Traceback (most recent call last):
  File "/sam2/training/train.py", line 271, in <module>
    main(args)
  File "/sam2/training/train.py", line 125, in main
    print(cfg.launcher.experiment_log_dir)
  File "/opt/conda/lib/python3.10/site-packages/omegaconf/dictconfig.py", line 359, in __getattr__
    self._format_and_raise(key=key, value=None, cause=e)
  File "/opt/conda/lib/python3.10/site-packages/omegaconf/base.py", line 231, in _format_and_raise
    format_and_raise(
  File "/opt/conda/lib/python3.10/site-packages/omegaconf/_utils.py", line 819, in format_and_raise
    _raise(ex, cause)
  File "/opt/conda/lib/python3.10/site-packages/omegaconf/_utils.py", line 797, in _raise
    raise ex.with_traceback(sys.exc_info()[2])  # set env var OC_CAUSE=1 for full trace
  File "/opt/conda/lib/python3.10/site-packages/omegaconf/dictconfig.py", line 351, in __getattr__
    return self._get_impl(
  File "/opt/conda/lib/python3.10/site-packages/omegaconf/dictconfig.py", line 442, in _get_impl
    node = self._get_child(
  File "/opt/conda/lib/python3.10/site-packages/omegaconf/basecontainer.py", line 73, in _get_child
    child = self._get_node(
  File "/opt/conda/lib/python3.10/site-packages/omegaconf/dictconfig.py", line 475, in _get_node
    self._validate_get(key)
  File "/opt/conda/lib/python3.10/site-packages/omegaconf/dictconfig.py", line 164, in _validate_get
    self._format_and_raise(
  File "/opt/conda/lib/python3.10/site-packages/omegaconf/base.py", line 231, in _format_and_raise
    format_and_raise(
  File "/opt/conda/lib/python3.10/site-packages/omegaconf/_utils.py", line 899, in format_and_raise
    _raise(ex, cause)
  File "/opt/conda/lib/python3.10/site-packages/omegaconf/_utils.py", line 797, in _raise
    raise ex.with_traceback(sys.exc_info()[2])  # set env var OC_CAUSE=1 for full trace
omegaconf.errors.ConfigAttributeError: Key 'launcher' is not in struct
    full_key: launcher
    object_type=dict
    ```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant