Taggers Table¶
Every camera trap image that has been taken is documented in this table.
Table Set Up¶
| Column Name | Content | Type | Unique | Nullable | Custom Constraints | Linked Table |
|---|---|---|---|---|---|---|
| ID | ID of entry | Integer | True | False | ||
| Name | name of person / AI that generated a tag | String(50) | True | False | ||
| Expertise | expertise label the tagger holds | Integer | False | False | Expertise ("ID") |
Functions¶
Test code for each function of the Taggers table is shown in Functions_Taggers.ipynb
In order to use the class functions, an instance of the class needs to be created
import T_Tables as tableClasses
#create class instance
Taggers = tableClasses.T_Taggers()
add¶
This function adds a tagger to the database.
Taggers.add(name: str, expertise: str)
Parameters
- name: unique name of the tagger
- expertise: name of the expertise label the tagger holds. This has to be documented in the Expertise Table
Returns
The function returns nothing.
delete¶
This function deletes a tagger from the database. Note, that a Tagger cannot be deleted if they have tagged an image, without its tag being removed first.
Taggers.delete(name: str)
Parameters
- name: name of the image you wish to delete
Returns
The function returns nothing.
update¶
This function allows you to update information of a given column for one entry
Taggers.update(name, colName: str, value)
Parameters
- name: name of the Tagger you wish to update
- colName: name of the column where you wish to update the value
- value: new value of given column. Make sure that the value matched the data type of the column
Returns
The function returns nothing.
get¶
This function gets all information for one Tagger.
Taggers.get(name: str)
Parameters
- name: name of the Tagger you wish to get information for
getAll¶
This function gets all information for a all Taggers.
Taggers.getAll()
Parameters
This Function has no parameters.
Returns
This function returns a pd.dataframe with one row for each documented Tagger.