genui.generators package
Subpackages
- genui.generators.extensions package
- Subpackages
- genui.generators.extensions.genuidrugex package
- Subpackages
- Submodules
- genui.generators.extensions.genuidrugex.admin module
- genui.generators.extensions.genuidrugex.apps module
- genui.generators.extensions.genuidrugex.genuisetup module
- genui.generators.extensions.genuidrugex.models module
- genui.generators.extensions.genuidrugex.serializers module
- genui.generators.extensions.genuidrugex.tasks module
- genui.generators.extensions.genuidrugex.tests module
- genui.generators.extensions.genuidrugex.torchutils module
- genui.generators.extensions.genuidrugex.urls module
- genui.generators.extensions.genuidrugex.views module
- Module contents
- genui.generators.extensions.genuidrugex package
- Module contents
- Subpackages
- genui.generators.migrations package
Submodules
genui.generators.admin module
- class genui.generators.admin.DrugExAgentAdmin(model, admin_site)[source]
Bases:
ModelAdmin
- property media
genui.generators.apps module
genui.generators.genuisetup module
genuisetup
Created by: Martin Sicho On: 4/28/20, 4:50 PM
genui.generators.models module
- class genui.generators.models.Generator(id, polymorphic_ctype, name, description, created, updated, project)[source]
Bases:
TaskShortcutsMixIn
,TaskMixin
,DataSet
- exception DoesNotExist
Bases:
ObjectDoesNotExist
- exception MultipleObjectsReturned
Bases:
MultipleObjectsReturned
- compounds
Accessor to the related objects manager on the reverse side of a many-to-one relation.
In the example:
class Child(Model): parent = ForeignKey(Parent, related_name='children')
Parent.children
is aReverseManyToOneDescriptor
instance.Most of the implementation is delegated to a dynamically defined manager class built by
create_forward_many_to_many_manager()
defined below.
- created
A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
- description
A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
- drugex
Accessor to the related object on the reverse side of a one-to-one relation.
In the example:
class Restaurant(Model): place = OneToOneField(Place, related_name='restaurant')
Place.restaurant
is aReverseOneToOneDescriptor
instance.
- get(n_samples) [<class 'str'>] [source]
All generators should override this. This should return a list of SMILES strings of size N.
- Returns
list of SMILES strings
- get_next_by_created(*, field=<django.db.models.fields.DateTimeField: created>, is_next=True, **kwargs)
- get_next_by_updated(*, field=<django.db.models.fields.DateTimeField: updated>, is_next=True, **kwargs)
- get_previous_by_created(*, field=<django.db.models.fields.DateTimeField: created>, is_next=False, **kwargs)
- get_previous_by_updated(*, field=<django.db.models.fields.DateTimeField: updated>, is_next=False, **kwargs)
- id
A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
- name
A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
- objects = <genui.utils.extensions.tasks.models.PolymorphicTaskManager object>
- polymorphic_ctype
The model field that stores the
ContentType
reference to the actual class.
- polymorphic_ctype_id
- polymorphic_primary_key_name = 'id'
- polymorphic_super_sub_accessors_replaced = False
- project
Accessor to the related object on the forward side of a many-to-one or one-to-one (via ForwardOneToOneDescriptor subclass) relation.
In the example:
class Child(Model): parent = ForeignKey(Parent, related_name='children')
Child.parent
is aForwardManyToOneDescriptor
instance.
- project_id
- tasks
Accessor to the related objects manager on the one-to-many relation created by GenericRelation.
In the example:
class Post(Model): comments = GenericRelation(Comment)
post.comments
is a ReverseGenericManyToOneDescriptor instance.
- updated
A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
genui.generators.serializers module
serializers
Created by: Martin Sicho On: 27-01-20, 17:00
genui.generators.signals module
signals
Created by: Martin Sicho On: 29-01-20, 13:12
genui.generators.urls module
urls
Created by: Martin Sicho On: 02-12-19, 17:18
genui.generators.views module
- class genui.generators.views.GeneratorAlgorithmViewSet(**kwargs)[source]
Bases:
AlgorithmViewSet
- basename = None
- description = None
- detail = None
- get_queryset()[source]
Get the list of items for this view. This must be an iterable, and may be a queryset. Defaults to using
self.queryset
.This method should always be used rather than accessing
self.queryset
directly, asself.queryset
gets evaluated only once, and those results are cached for all subsequent requests.You may want to override this if you need to provide different querysets depending on the incoming request.
(Eg. return a list of items that is specific to the user)
- name = None
- suffix = None
- class genui.generators.views.GeneratorMetricsViewSet(**kwargs)[source]
Bases:
MetricsViewSet
- basename = None
- description = None
- detail = None
- get_queryset()[source]
Get the list of items for this view. This must be an iterable, and may be a queryset. Defaults to using
self.queryset
.This method should always be used rather than accessing
self.queryset
directly, asself.queryset
gets evaluated only once, and those results are cached for all subsequent requests.You may want to override this if you need to provide different querysets depending on the incoming request.
(Eg. return a list of items that is specific to the user)
- name = None
- suffix = None
- class genui.generators.views.GeneratorViewSet(**kwargs)[source]
Bases:
FilterToProjectMixIn
,FilterToUserMixIn
,ListModelMixin
,DestroyModelMixin
,GenericViewSet
- basename = None
- description = None
- detail = None
- name = None
- owner_relation = 'project__owner'
- project_id_param = {'description': 'Return generators related to just the project with this ID.', 'in': 'query', 'name': 'project_id', 'type': 'number'}
- queryset
- serializer_class
alias of
GeneratorSerializer
- suffix = None