neurai.manager package#

Submodules#

class neurai.manager.ide_manager.ProgressData(value, desc)#

Bases: object

when __register_progress_callback, the event will be passed.

Parameters:
  • value (float) – the range is 0.0 ~ 1.0

  • desc (str) – description of the stage

class neurai.manager.rng_manager.RngManager(rng=None, name='')#

Bases: object

The base class for RngManager.

Parameters:
  • rng (PRNGKey,) – the PRNGKey, by default default_rng.

  • name (str, optional) – the module name, by default None.

static trans(new_name)#

Transform the string to an int using an SHA-1 hash.

Parameters:

new_name (str, optional) – the new module name

Return type:

int

class neurai.manager.var_manager.Variable(vm, collection, name)#

Bases: object

A Variable object allows mutable access to a variable in a VariableDict.

Variables are identified by a collection (e.g., “batch_stats”) and a name (e.g., “moving_mean”). The value property gives access to the variable’s content.

Parameters:
  • vm (VarManager) – The variable Manager

  • collection (str) – The collection of the variable (e.g., “params”)

  • name (str) – The name of the variable (e.g., “dense”)

Module contents#