(*args, **kwargs)
| 46 | def check_bytes_allocated(f): |
| 47 | @wraps(f) |
| 48 | def wrapper(*args, **kwargs): |
| 49 | gc.collect() |
| 50 | allocated_bytes = pa.total_allocated_bytes() |
| 51 | try: |
| 52 | return f(*args, **kwargs) |
| 53 | finally: |
| 54 | assert pa.total_allocated_bytes() == allocated_bytes |
| 55 | return wrapper |
| 56 | |
| 57 |