Skip to content
GitLab
Projects Groups Topics Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
  • Melissa Melissa
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributor statistics
    • Graph
    • Compare revisions
  • Issues 4
    • Issues 4
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 9
    • Merge requests 9
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Package Registry
    • Container Registry
    • Terraform modules
  • Monitor
    • Monitor
    • Metrics
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • melissamelissa
  • MelissaMelissa
  • Merge requests
  • !106

Fix timeout issue in new buffer

  • Review changes

  • Download
  • Patches
  • Plain diff
Merged Lucas Meyer requested to merge fix-buffer into develop Mar 21, 2023
  • Overview 0
  • Commits 2
  • Pipelines 2
  • Changes 2

This MR should fix the error noticed by @rcaulk:

2023-03-21 14:50:43,586:melissa.server.deep_learning.base_dl_server:ERROR Exception was raised in the receiving thread: empty range for randrange() Traceback (most recent call last): File "/gpfswork/rech/igf/commun/uhd97cp/melissa/melissa/server/deep_learning/base_dl_server.py", line 139, in receive self.buffer.put(data) File "/gpfswork/rech/igf/commun/uhd97cp/melissa/melissa/server/deep_learning/buffer.py", line 148, in put super().put(watched_item, block, timeout) # type: ignore File "/gpfswork/rech/igf/commun/uhd97cp/melissa/melissa/server/deep_learning/buffer.py", line 122, in put add_item = self._on_full(block=block, timeout=timeout) File "/gpfswork/rech/igf/commun/uhd97cp/melissa/melissa/server/deep_learning/buffer.py", line 318, in _on_full index = random.randrange(len(self.seen)) File "/gpfslocalsup/pub/anaconda-py3/2022.05/envs/pytorch-gpu-1.13.0+py3.10.8/lib/python3.10/random.py", line 321, in randrange raise ValueError("empty range for randrange()") ValueError: empty range for randrange() 2023-03-21 14:50:43,602:melissa.server.base_server:ERROR The server failed with an error

When the buffer is full, i.e. the container is full and no sample has been seen already, the put should wait until timeout possibly none is reach.

Assignee
Assign to
Reviewers
Request review from
Time tracking
Source branch: fix-buffer