revitron.analyze

The revitron.analyze module helps you to automate analysing the health and status of a model and to extract several types of data and statistics in order to simplifiy BIM quality control. Extracted data is stored as snapshots in a SQLite database to be consumed by other applications or dashboards.

class DataProviderResult(providerClass, providerName, providerConfig)[source]

Bases: object

The DataProviderResult object handles the execution of a data provider by creating a unified results object containing the provider name, the resulting value and its data type.

__init__(providerClass, providerName, providerConfig)[source]

Inits a new provider class instances and runs the provider’s run() method in order to populate the value property.

Parameters
  • providerClass (string) – The class name for the data provider that has to be used

  • providerName (string) – A descriptive name to generate the storage field

  • providerConfig (dict) – The configuration that is passed to the data provider

property dataType

The data type that is used to store the value.

Returns

The data type

Return type

string

property name

The name that is used to create a storage field.

Returns

The field name

Return type

string

property value

The resulting value.

Returns

The value that is returned by the provider’s run() method

Return type

mixed

class ModelAnalyzer(configJson, cliLog)[source]

Bases: object

The ModelAnalyzer class applies a configured set of data providers on a model and creates snapshots with the extracted statistics in a given SQLite database.

__init__(configJson, cliLog)[source]

Init a ModelAnalyzer instance.

Parameters
  • configJson (string) – The configuration JSON file

  • cliLog (CliLog) – The CLI log instance

snapshot()[source]

Create a snapshot and store the given DataProviderResult list along with a timestamp using a given storage driver.

Submodules