Does Ray Offer any Functional/Declarative Interface to Map a Remote Function to an Iterator/Iterable?
My present Code #!/usr/bin/env python3 # encoding: utf-8 “””Demonstration of Ray parallelism””” import ray from typing import Iterator ray.init() @ray.remote def square(n:int)->int: return n*n references: Iterator[ray.ObjectRef] = map(lambda val: square.remote(val), range(10)) ray.get([*references]) ray.shutdown() Basically, nothing but a form of map(square, range(10)) powered by Ray. Question For such a standard and common pattern, the above operation […]