I'm in the research environment wanting to leverage parallel processing. It seems to me that I don't have the ability to do that in the Research environment. What are some ways I can do parallel processing? Or should I just do this type of research on my local using the Lean CLI?

I'm using the following code to test:

from joblib import Parallel, delayed 

# Dummy function for testing parallel processing 
def sample_task(x): return x ** 2 

# Without parallel processing 
start = time.time() 
results = [sample_task(i) for i in range(1000000)] 
end = time.time() 
print(f"Execution time without parallel processing: {end - start:.2f} seconds") 

# With parallel processing 
start = time.time() 
results_parallel = Parallel(n_jobs=-1)(delayed(sample_task)(i) for i in range(1000000)) 
end = time.time() 
print(f"Execution time with parallel processing: {end - start:.2f} seconds")