core

Metadata for entities that are used in multiple contexts (e.g. in both electrophysiology and in simulation).

class fairgraph.core.Subject(name, species, age=None, sex=None, handedness=None, strain=None, genotype=None, death_date=None, group=None, id=None, instance=None)[source]

Bases: fairgraph.base.KGObject

The individual organism that is the subject of an experimental study.

Parameters:
class fairgraph.core.Organization(name, address=None, parent=None, id=None, instance=None)[source]

Bases: fairgraph.base.KGObject

An organization associated with research data or models, e.g. a university, lab or department.

Parameters:
class fairgraph.core.Person(family_name, given_name, email=None, affiliation=None, id=None, instance=None)[source]

Bases: fairgraph.base.KGObject

A person associated with research data or models, for example as an experimentalist,
or a data analyst.
Parameters:
  • family_name (str) – Family name / surname
  • given_name (str) – Given name
  • email (str) – e-mail address
  • affiliation (Organization) – Organization to which person belongs
classmethod list(client, size=100, api='query', scope='released', resolved=False, **filters)[source]

List all objects of this type in the Knowledge Graph

resolve(client, api='query', use_cache=True)[source]

To avoid having to check if a child attribute is a proxy or a real object, a real object resolves to itself.

classmethod me(client, api='query', allow_multiple=False)[source]

Return the Person who is currently logged-in.

(the user associated with the token stored in the client).

If the Person node does not exist in the KG, it will be created.

class fairgraph.core.Identifier(id=None, instance=None, **properties)[source]

Bases: fairgraph.base.KGObject

class fairgraph.core.Material(name, molar_weight=None, formula=None, stock_keeping_unit=None, reagent_distribution=None, vendor=None, id=None, instance=None)[source]

Bases: fairgraph.base.KGObject

Metadata about a chemical product or other material used in an experimental protocol.

Parameters:
  • name (str) –
  • molar_weight (QuantitativeValue) –
  • formula (str) –
  • stock_keeping_unit (str) –
  • reagent_distribution (Distribution) –
  • vendor (Organization) –
class fairgraph.core.Step(name, previous_step_name=None, sequence_number=None, identifier=None, version=None, distribution=None, description=None, materials=None, author=None, id=None, instance=None)[source]

Bases: fairgraph.base.KGObject

A step in an experimental protocol.

Parameters:
  • name (str, int) –
  • previous_step_name (str, int) –
  • sequence_number (int) –
  • identifier (str) –
  • version (str, int) –
  • distribution (Distribution) –
  • description (str) –
  • materials (Material) –
  • author (Person) –
class fairgraph.core.Protocol(name, version=None, identifier=None, doi=None, distribution=None, number_of_steps=None, steps=None, materials=None, author=None, date_published=None, id=None, instance=None)[source]

Bases: fairgraph.base.KGObject

An experimental protocol.

Parameters:
  • name (str) –
  • version (str, int) –
  • identifier (str) –
  • distribution (Distribution) –
  • number_of_steps (int) –
  • steps (Step) –
  • materials (Material) –
  • author (Person) –
  • date_published (date) –
class fairgraph.core.Collection(name, members, id=None, instance=None)[source]

Bases: fairgraph.base.KGObject

A collection of other metadata objects

Parameters:
  • name (str) –
  • members (KGObject) –
fairgraph.core.list_kg_classes()[source]

List all KG classes defined in this module

fairgraph.core.use_namespace(namespace)[source]

Set the namespace for all classes in this module.