Skip to content

Commit 07e1a1b

Browse files
authored
Merge branch 'staging' into fix_conflicts
2 parents e2cf287 + 74d8686 commit 07e1a1b

File tree

5 files changed

+43
-17
lines changed

5 files changed

+43
-17
lines changed

CHANGELOG.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,14 @@
22

33
Observes [Semantic Versioning](https://semver.org/spec/v2.0.0.html) standard and [Keep a Changelog](https://keepachangelog.com/en/1.0.0/) convention.
44

5+
## [0.3.1] - 2024-01-12
6+
7+
+ Update - `BehaviorRecording.File` table's attribute `filepath` length to `varchar(256)`
8+
9+
## [0.3.0] - 2023-11-09
10+
11+
+ Add - `BehaviorTimeSeries` table
12+
513
## [0.2.5] - 2024-10-25
614

715
+ Update - `trial_type` to varchar(24) in `TrialType` table
@@ -52,6 +60,8 @@ Observes [Semantic Versioning](https://semver.org/spec/v2.0.0.html) standard and
5260
+ Add - AlignmentEvent design to capture windows relative to an event
5361
+ Add - Black formatting into code base
5462

63+
[0.3.1]: https://github.com/datajoint/element-event/releases/tag/0.3.1
64+
[0.3.0]: https://github.com/datajoint/element-event/releases/tag/0.3.0
5565
[0.2.5]: https://github.com/datajoint/element-event/releases/tag/0.2.5
5666
[0.2.4]: https://github.com/datajoint/element-event/releases/tag/0.2.4
5767
[0.2.3]: https://github.com/datajoint/element-event/releases/tag/0.2.3

LICENSE

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
MIT License
22

3-
Copyright (c) 2022 DataJoint
3+
Copyright (c) 2024 DataJoint
44

55
Permission is hereby granted, free of charge, to any person obtaining a copy
66
of this software and associated documentation files (the "Software"), to deal

element_event/event.py

Lines changed: 21 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -128,12 +128,12 @@ class File(dj.Part):
128128
129129
Attributes:
130130
BehaviorRecording (foreign key): Behavior recording primary key.
131-
filepath ( varchar(64) ): file path of video, relative to root data dir.
131+
filepath ( varchar(256) ): file path of video, relative to root data dir.
132132
"""
133133

134134
definition = """
135135
-> master
136-
filepath : varchar(64)
136+
filepath : varchar(256)
137137
"""
138138

139139

@@ -146,14 +146,14 @@ class Event(dj.Imported):
146146
Attributes:
147147
BehaviorRecording (foreign key): Behavior recording primary key.
148148
EventType (foreign key): EventType primary key.
149-
event_start_time (decimal(10, 4)): Time of event onset in seconds, WRT recording start.
149+
event_start_time (decimal): Time of event onset in seconds, WRT recording start.
150150
event_end_time (float): Optional. Seconds WRT recording start.
151151
"""
152152

153153
definition = """
154154
-> BehaviorRecording
155155
-> EventType
156-
event_start_time : decimal(10, 4) # (second) relative to recording start
156+
event_start_time : decimal(10, 6) # (second) relative to recording start
157157
---
158158
event_end_time=null : float # (second) relative to recording start
159159
"""
@@ -211,3 +211,20 @@ class AlignmentEvent(dj.Manual):
211211
-> EventType.proj(end_event_type='event_type') # event after alignment_event_type
212212
end_time_shift: float # (s) WRT end_event_type
213213
"""
214+
215+
216+
@schema
217+
class BehaviorTimeSeries(dj.Imported):
218+
definition = """
219+
-> BehaviorRecording
220+
timeseries_name : varchar(32) # e.g. joystick, lick_port
221+
---
222+
sample_rate=null : float # (Hz) # sampling rate of the acquired data
223+
behavior_timeseries : longblob # array of device's acquired data
224+
behavior_timestamps=null : longblob # array of timestamps (in second) relative to the start of the BehaviorRecording
225+
timeseries_description='' : varchar(1000) # detailed description about the timeseries
226+
"""
227+
228+
def make(self, key):
229+
"""Populate based on unique entries in BehaviorRecording."""
230+
# Write a make function to automatically ingest your timeseries data.

element_event/version.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,2 @@
11
"""Package metadata."""
2-
3-
__version__ = "0.2.5"
2+
__version__ = "0.3.1"

setup.py

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -4,27 +4,27 @@
44
pkg_name = "element_event"
55
here = path.abspath(path.dirname(__file__))
66

7-
with open(path.join(here, 'README.md'), 'r') as f:
7+
with open(path.join(here, "README.md"), "r") as f:
88
long_description = f.read()
99

10-
with open(path.join(here, 'requirements.txt')) as f:
10+
with open(path.join(here, "requirements.txt")) as f:
1111
requirements = f.read().splitlines()
1212

13-
with open(path.join(here, pkg_name, 'version.py')) as f:
13+
with open(path.join(here, pkg_name, "version.py")) as f:
1414
exec(f.read())
1515

1616
setup(
17-
name=pkg_name.replace('_', '-'),
17+
name=pkg_name.replace("_", "-"),
1818
version=__version__,
1919
description="DataJoint Elements for Trialized Experiments",
2020
long_description=long_description,
21-
long_description_content_type='text/markdown',
22-
author='DataJoint',
23-
author_email='[email protected]',
24-
license='MIT',
21+
long_description_content_type="text/markdown",
22+
author="DataJoint",
23+
author_email="[email protected]",
24+
license="MIT",
2525
url=f'https://github.com/datajoint/{pkg_name.replace("_", "-")}',
26-
keywords='neuroscience behavior bpod trials datajoint',
27-
packages=find_packages(exclude=['contrib', 'docs', 'tests*']),
26+
keywords="neuroscience behavior bpod trials datajoint",
27+
packages=find_packages(exclude=["contrib", "docs", "tests*"]),
2828
scripts=[],
2929
install_requires=requirements,
3030
)

0 commit comments

Comments
 (0)