inferlo.DiscreteDomain

class inferlo.DiscreteDomain[source]

Domain consisting of finite set of numbers.

__init__(values)[source]

Methods

__init__(values)

binary()

Creates domain with two values 0 and 1.

get_value_index(val)

Gets number of given value in list of al values in domain.

is_discrete()

Whether the domain is discrete.

range(n)

Creates domain with integer values from 0 to n-1.

size()

Cardinality of the domain.

static binary()[source]

Creates domain with two values 0 and 1.

get_value_index(val)[source]

Gets number of given value in list of al values in domain.

is_discrete()[source]

Whether the domain is discrete.

static range(n: int)[source]

Creates domain with integer values from 0 to n-1.

size()[source]

Cardinality of the domain.