code: def perform_allocations(self, actor_bytes, nested_task_bytes):
      self.mem = alloc_mem(actor_bytes)
      if self.barrier:
          ray.get(self.barrier.wait_all_done.remote())
      ray.get(
          allocate_memory.options(max_retries=0).remote(
              nested_task_bytes
          )
      )
  
imports: import sys
  import threading
  import pytest
  import ray
  from ray.tests.test_memory_pressure import allocate_memory, Leaker, get_additional_bytes_to_reach_memory_usage_pct, memory_usage_threshold, memory_monitor_refresh_ms
label_desc: Use image node_id 2 for calling the ActorWithNestedTask obj's underlying member method code with example usage: obj.perform_allocations(actor_bytes, nested_task_bytes) without return types