Skip to content

Commit

Permalink
Merge pull request #602 from rapidsai/branch-23.08
Browse files Browse the repository at this point in the history
Forward-merge branch-23.08 to branch-23.10
  • Loading branch information
GPUtester authored Aug 3, 2023
2 parents 9873d73 + 1408971 commit c0805d9
Showing 1 changed file with 5 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ def test_read_region_cuda_memleak(testimg_tiff_stripe_4096x4096_256_jpeg):
gpu = gpus[0]
mem_usage_history = [gpu.memoryUsed]

for i in range(5):
for i in range(10):
_ = img.read_region(device='cuda')
gpus = GPUtil.getGPUs()
gpu = gpus[0]
Expand All @@ -40,8 +40,10 @@ def test_read_region_cuda_memleak(testimg_tiff_stripe_4096x4096_256_jpeg):

# The difference in memory usage should be less than 180MB.
# Note: Since we cannot measure GPU memory usage for a process,
# we use a rough number (experimentally measured).
assert mem_usage_history[4] - mem_usage_history[1] < 180.0
# we use a rough number.
# (experimentally measured, assuming that each image load
# consumes around 50MB of GPU memory).
assert mem_usage_history[5] - mem_usage_history[9] < 180.0


def test_read_region_cpu_memleak(testimg_tiff_stripe_4096x4096_256):
Expand Down

0 comments on commit c0805d9

Please sign in to comment.