API Reference

Global Methods

At the time, tensorscout is a lean module composed of 3 decorators.

class tensorscout.cakerun(num_cores, L_sectors)

This decorator partitions an array into sectors and applies a given function to each sector in parallel. The result of each computation is merged into a final output array.

Parameters

num_cores: int

Number of processors to use

L_sectorsint

The length scale for the number of sectors [per column]. For non-square arrays, the number of sectors per row gets adjusted as a function of this value

class tensorscout.campfire(num_iters, num_cores)

Much like a campfire which brings people together and allow for sharing stories and experiences, this decorator brings together the results of simulations across num_cores multiple processors and regroups them in a dictionary by key.

Parameters

num_cores: int

Number of processors to use

num_itersint

The number of iterations to perform for a specific model / Monte Carlo simulation.

class tensorscout.multicarlo(num_iters, num_cores)

This decorator performs a non-dynamic operation or task for a specified number of iterations num_iters and distributes the tasks across a requested number of available processors num_cores.

Parameters

num_cores: int

Number of processors to use

num_itersint

The number of iterations to perform for a specific model / Monte Carlo simulation.