For general questions or debugging development errors as a result of using DataJoint, a framework for scientific workflow management. For assistance with debugging, please include: Client OS, DataJoint Client (Python|MATLAB|LabBook|Pharus), DataJoint Version, and Database Version (MySQL 5.7|MariaDB 10.5|etc).
Questions tagged [datajoint]
50 questions
0
votes
0 answers
Foreign key reference could not be resolved immediately after defining
The following code
@schema
class A(dj.Manual):
definition = """
a: varchar(1)
"""
a = A()
a.insert1(["a"], skip_duplicates=True)
@schema
class B(dj.Manual):
definition = """
b: varchar(1)
"""
@schema
class…

zagaroo
- 31
- 4
0
votes
1 answer
Generate a table subset with a list
I have a set of subjects in a table, and I want delete a subset (e.g., subject1 and subject2). Is there a way to fetch a subset using a list? Or do I need to have an attribute I can use to select the subset?
subject.Subject()
# *subject sex …

Chris Broz
- 136
- 8
0
votes
2 answers
Alternative way to list all part tables that have existing entries/tuples
I have one single master Subject table which have several part tables. One convenient thing about Table.delete() is that is displays a prompt with all existing entries that were created under that Subject. Aside from delete() is there an…

Sahil
- 5
- 2
0
votes
2 answers
Is there a way to stop datajoint from asking for username and password when I import it
In Datajoint, you are prompted for username and password. I am creating a readthedocs website with Sphinx and I need the system to not prompt for username and password. How can I turn it off?

Phil
- 2,143
- 19
- 44
0
votes
2 answers
Nested MATLAB struct is difficult to parse when fetched in DataJoint Python
From DataJoint Python and DataJoint MATLAB, I have inserted the same values into a longblob attribute. From DataJoint Python it was inserted as a dictionary and from DataJoint MATLAB it was inserted as a struct. The entry that was inserted with…

kabilar
- 1
- 2
0
votes
1 answer
validating parameter dictionaries before insertion in datajoint schema
We'd like to enforce parameter checking before people can insert into a schema as shown below, but the code below doesn't work.
Is there a way to implement pre-insertion parameter checking?
@schema
class AutomaticCurationParameters(dj.Manual):
…

Loren Frank
- 43
- 2
0
votes
1 answer
What is the purpose of FreeTable? It does not have the same behavior as user tables. It is not covered in the documentation
Environment: DataJoint version (0.12.9) on Ubuntu with MySQL 5.7
The concept of FreeTable is nice. Provide a dj.conn() object and full_table_name and a table you can manipulate is created, independent of modules, virtual modules and…

spapadop
- 51
- 5
0
votes
1 answer
MySQL OperationalError when deleting from DataJoint table after restricting with its part table: "You can't specify target table : 'part_table'"
Using DataJoint Python (0.12.9) on Ubuntu with MySQL 5.7 .
Am running into an error with what I believed to be a fairly standard operation.
Have a table named Table with a part Table.Part.
Restricting Table as such:
Table & Table.Part
gives me…

spapadop
- 51
- 5
0
votes
1 answer
Specifying table dependency when many entries in upstream table for one entry in downstream table
I would like to create a datajoint computed table that depends on multiple entries (about 20) from an upstream table. I know it is possible to create a table that depends on multiple entries from an upstream table using the .proj method to rename a…

jguides
- 27
- 4
0
votes
1 answer
Querying a varchar entry for a partial string
I am wondering if there is a way to query a table for a partial match to a string.
For instance, I have a table that lists drug treatments, but sometimes there are multiple drugs in
a single treatment. These come into the database as a varchar entry…

anna1ntegrated
- 1
- 2
0
votes
1 answer
Datajoint dependencies with custom key_source
I use non-dependent tables to restrict using a custom key source. As an example, my pipeline stages are all parameterized and use a mixin key_source to specify which parameters are used for each stage for a given dataset:
class ParamsMixin:
…

HoosierDaddy
- 720
- 6
- 19
0
votes
1 answer
Setting datajoint key to a different variable in make fxn
Wondering why and when it's needed to set the key to a different variable in a make/maketuples function in an auto-populated table in datajoint, as in the documentation here.
In this example, the part table SegmentationROI is defined as…

jbussell
- 15
- 2
0
votes
1 answer
Drop a Datajoint schema in Matlab? List schemas on the database server?
Looking for how to remove an entire Datajoint schema from the SQL database server using the Matlab 3.4 implementation of datajoint (the equivalent of schema.drop(True) in Python)
as well as how to list all schemas that exist on the server…

jbussell
- 15
- 2
0
votes
1 answer
Cannot repopulate ElectrodeGroup datajoint table
I'm a researcher in Loren Frank's lab at UCSF using datajoint and files in the nwb format. I made some changes to our code for defining entries in our ElectrodeGroup table, and was hoping to test those by deleting an entry in the table and…

jguides
- 27
- 4
0
votes
1 answer
Datajoint scientific pipeline: how to efficiently store data and design pipeline when attributes can change and data come from arrays
We need to load the output from our neuroscience animal behavior training sessions into our datajoint database pipeline. We run experiments with a platform called Bpod that implements a finite state machine on an Arduino to control hardware and…

jbussell
- 15
- 2