WARNING: This function must never be called.
It may only be used with future::plan()
Usage
cluster(
cluster = p2p_cluster_name(),
host = "pipe.pico.sh",
ssh_args = NULL,
...
)
availablePicoP2PWorkers()
Value
An object of class PicoP2PFuture
.
availablePicoP2PWorkers()
returns the number of registered workers on the P2P cluster.
It will always return at least one worker, which is yourself.
WARNING: This is currently hardcoded to 10 workers, regardless of the number.
Details
A 'p2p' future is an asynchronous multiprocess future that will be evaluated in a background R session.
The Pico P2P future backend relies on Pico (1) to distribute futures among a peer-to-peer (P2P) cluster of R workers. Users with a Pico account can join the P2P cluster by being invited to a shared folder.
Users who wish to contribute their compute power to the P2P cluster
should call worker()
.
Users who wish to take advantage of the compute power of the
P2P cluster should use plan(future.p2p::cluster)
.
References
pico.sh, The ultimate ssh powered services for developers, https://pico.sh/.