Reference Python¶
mousetube_api.models
¶
User
¶
Bases: Model
Represents a user of the system.
Attributes:
Name | Type | Description |
---|---|---|
name_user |
str
|
The last name of the user. |
first_name_user |
str
|
The first name of the user. |
email_user |
str
|
The email address of the user. |
unit_user |
str
|
The unit the user belongs to. |
institution_user |
str
|
The institution the user belongs to. |
address_user |
str
|
The address of the user. |
country_user |
str
|
The country of the user. |
Source code in mousetube_api/models.py
13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 |
|
__str__()
¶
Returns the full name of the user.
Returns:
Name | Type | Description |
---|---|---|
str |
The full name of the user. |
Source code in mousetube_api/models.py
35 36 37 38 39 40 41 42 |
|
Strain
¶
Bases: Model
Represents a strain of a mouse.
Attributes:
Name | Type | Description |
---|---|---|
name_strain |
str
|
The name of the strain. |
background |
str
|
The genetic background of the strain. |
biblio_strain |
str
|
Bibliographical references related to the strain. |
Source code in mousetube_api/models.py
45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 |
|
__str__()
¶
Returns the name of the strain as a string.
Returns:
Name | Type | Description |
---|---|---|
str |
The name of the strain. |
Source code in mousetube_api/models.py
59 60 61 62 63 64 65 66 |
|
Subject
¶
Bases: Model
Represents a subject (mouse) in the system.
Attributes:
Name | Type | Description |
---|---|---|
name_subject |
str
|
The name of the subject. |
strain_subject |
Strain
|
The strain associated with the subject. |
origin_subject |
str
|
The origin of the subject. |
sex_subject |
str
|
The sex of the subject. |
group_subject |
str
|
The group the subject belongs to. |
genotype_subject |
str
|
The genotype of the subject. |
treatment |
str
|
The treatment applied to the subject. |
user |
User
|
The user associated with the subject. |
Source code in mousetube_api/models.py
73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 |
|
__str__()
¶
Returns the name of the subject.
Returns:
Name | Type | Description |
---|---|---|
str |
The name of the subject. |
Source code in mousetube_api/models.py
97 98 99 100 101 102 103 104 |
|
Protocol
¶
Bases: Model
Represents an experimental protocol.
Attributes:
Name | Type | Description |
---|---|---|
name_protocol |
str
|
The name of the protocol. |
number_files |
int
|
The number of files associated with the protocol. |
protocol_description |
str
|
A description of the protocol. |
user |
User
|
The user associated with the protocol. |
Source code in mousetube_api/models.py
111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 |
|
__str__()
¶
Returns the name of the protocol.
Returns:
Name | Type | Description |
---|---|---|
str |
The name of the protocol. |
Source code in mousetube_api/models.py
127 128 129 130 131 132 133 134 |
|
Experiment
¶
Bases: Model
Represents an experiment.
Attributes:
Name | Type | Description |
---|---|---|
name_experiment |
str
|
The name of the experiment. |
protocol |
Protocol
|
The protocol associated with the experiment. |
group_subject |
str
|
The group of subjects involved in the experiment. |
date_experiment |
date
|
The date of the experiment. |
temperature |
str
|
The temperature during the experiment. |
light_cycle |
str
|
The light cycle during the experiment. |
microphone |
str
|
The microphone used in the experiment. |
acquisition_hardware |
str
|
The hardware used for acquisition. |
acquisition_software |
str
|
The software used for acquisition. |
sampling_rate |
float
|
The sampling rate of the data. |
bit_depth |
float
|
The bit depth of the data. |
laboratory |
str
|
The laboratory where the experiment was conducted. |
Source code in mousetube_api/models.py
141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 |
|
__str__()
¶
Returns the name of the experiment.
Returns:
Name | Type | Description |
---|---|---|
str |
The name of the experiment. |
Source code in mousetube_api/models.py
173 174 175 176 177 178 179 180 |
|
File
¶
Bases: Model
Represents a file associated with an experiment or subject.
Attributes:
Name | Type | Description |
---|---|---|
experiment |
Experiment
|
The experiment associated with the file. |
subject |
Subject
|
The subject associated with the file. |
file_number |
int
|
The number of the file. |
link_file |
str
|
The URL link to the file. |
notes_file |
str
|
Notes about the file. |
doi_file |
str
|
The DOI of the file. |
is_valid_link |
bool
|
Whether the link is valid. |
Source code in mousetube_api/models.py
187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 |
|
__str__()
¶
Returns the link to the file.
Returns:
Name | Type | Description |
---|---|---|
str |
The URL link to the file. |
Source code in mousetube_api/models.py
213 214 215 216 217 218 219 220 |
|
PageView
¶
Bases: Model
Represents a page view for tracking purposes.
Attributes:
Name | Type | Description |
---|---|---|
path |
str
|
The path of the page. |
date |
date
|
The date of the page view. |
count |
int
|
The number of views for the page on the given date. |
Source code in mousetube_api/models.py
227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 |
|
__str__()
¶
Returns a string representation of the page view.
Returns:
Name | Type | Description |
---|---|---|
str |
The path, date, and count of the page view. |
Source code in mousetube_api/models.py
244 245 246 247 248 249 250 251 |
|