Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feat 36 bump version pins #87

Closed
wants to merge 3 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ readme = "README.md"
dynamic = ["version"]

dependencies = [
"aind-data-schema==0.36.0",
"aind-data-schema==0.38.0",
"aind-data-schema-models==0.1.7",
"pydantic-settings>=2.0",
"pandas",
Expand Down
5 changes: 3 additions & 2 deletions src/aind_metadata_mapper/bergamo/session.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""Module to map bergamo metadata into a session model."""

import argparse
import bisect
import json
Expand Down Expand Up @@ -1154,15 +1155,15 @@ def run_job(self) -> JobResponse: # noqa: C901
stimulus_parameters=[photostim],
# opticalBCI class to be added in future
stimulus_device_names=self.job_settings.stimulus_device_names,
light_source_config=LaserConfig(
light_source_config=[LaserConfig(
# from rig json
name=self.job_settings.photostim_laser_name,
wavelength=self.job_settings.photostim_laser_wavelength,
# user set value
excitation_power=np.nanmean(group_powers),
# from tiff header,
excitation_power_unit=PowerUnit.PERCENT,
),
)],
output_parameters={
"tiff_files": tiff_list,
"tiff_stem": tiff_stem,
Expand Down
12 changes: 6 additions & 6 deletions src/aind_metadata_mapper/open_ephys/utils/behavior_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -730,9 +730,9 @@ def fix_omitted_end_frame(stim_pres_table: pd.DataFrame) -> pd.DataFrame:
stim_pres_table[stim_pres_table["omitted"]]["start_frame"]
+ median_stim_frame_duration
)
stim_pres_table.loc[
stim_pres_table["omitted"], "end_frame"
] = omitted_end_frames
stim_pres_table.loc[stim_pres_table["omitted"], "end_frame"] = (
omitted_end_frames
)

stim_dtypes = stim_pres_table.dtypes.to_dict()
stim_dtypes["start_frame"] = int
Expand Down Expand Up @@ -796,9 +796,9 @@ def compute_is_sham_change(
if np.array_equal(
active_images, stim_image_names[passive_block_mask].values
):
stim_df.loc[
passive_block_mask, "is_sham_change"
] = stim_df[active_block_mask]["is_sham_change"].values
stim_df.loc[passive_block_mask, "is_sham_change"] = (
stim_df[active_block_mask]["is_sham_change"].values
)

return stim_df.sort_index()

Expand Down
1 change: 1 addition & 0 deletions src/aind_metadata_mapper/open_ephys/utils/constants.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
""" Constants for the naming utils of metadata mapper """

import re

INT_NULL = -99
Expand Down
2 changes: 1 addition & 1 deletion tests/resources/bergamo/expected_session.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"describedBy": "https://raw.githubusercontent.com/AllenNeuralDynamics/aind-data-schema/main/src/aind_data_schema/core/session.py",
"schema_version": "0.2.6",
"schema_version": "0.3.1",
"protocol_id": [],
"experimenter_full_name": [
"John Apple"
Expand Down
2 changes: 1 addition & 1 deletion tests/resources/bruker/expected_session.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"describedBy": "https://raw.githubusercontent.com/AllenNeuralDynamics/aind-data-schema/main/src/aind_data_schema/core/session.py",
"schema_version": "0.2.6",
"schema_version": "0.3.1",
"protocol_id": [
""
],
Expand Down
7 changes: 2 additions & 5 deletions tests/resources/dynamic_routing/base-missing-probe_rig.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"describedBy": "https://raw.githubusercontent.com/AllenNeuralDynamics/aind-data-schema/main/src/aind_data_schema/core/rig.py",
"schema_version": "0.3.8",
"schema_version": "0.5.1",
"rig_id": "327_NP2_240401",
"modification_date": "2024-04-01",
"mouse_platform": {
Expand Down Expand Up @@ -233,7 +233,6 @@
"data_interface": "Ethernet",
"cooling": "None",
"computer_name": "127.0.0.1",
"max_frame_rate": "102",
"frame_rate_unit": "hertz",
"immersion": null,
"chroma": "Monochrome",
Expand Down Expand Up @@ -375,7 +374,6 @@
"data_interface": "Ethernet",
"cooling": "None",
"computer_name": "127.0.0.1",
"max_frame_rate": "102",
"frame_rate_unit": "hertz",
"immersion": null,
"chroma": "Monochrome",
Expand Down Expand Up @@ -514,7 +512,6 @@
"data_interface": "Ethernet",
"cooling": "None",
"computer_name": "127.0.0.1",
"max_frame_rate": "102",
"frame_rate_unit": "hertz",
"immersion": null,
"chroma": "Monochrome",
Expand Down Expand Up @@ -1007,7 +1004,7 @@
"data_interface": "Other",
"cooling": "Air",
"computer_name": null,
"max_frame_rate": null,

"frame_rate_unit": "hertz",
"immersion": null,
"chroma": null,
Expand Down
7 changes: 2 additions & 5 deletions tests/resources/dynamic_routing/base_rig.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"describedBy": "https://raw.githubusercontent.com/AllenNeuralDynamics/aind-data-schema/main/src/aind_data_schema/core/rig.py",
"schema_version": "0.3.8",
"schema_version": "0.5.1",
"rig_id": "327_NP2_240401",
"modification_date": "2024-04-01",
"mouse_platform": {
Expand Down Expand Up @@ -233,7 +233,6 @@
"data_interface": "Ethernet",
"cooling": "None",
"computer_name": "127.0.0.1",
"max_frame_rate": "102",
"frame_rate_unit": "hertz",
"immersion": null,
"chroma": "Monochrome",
Expand Down Expand Up @@ -375,7 +374,6 @@
"data_interface": "Ethernet",
"cooling": "None",
"computer_name": "127.0.0.1",
"max_frame_rate": "102",
"frame_rate_unit": "hertz",
"immersion": null,
"chroma": "Monochrome",
Expand Down Expand Up @@ -514,7 +512,6 @@
"data_interface": "Ethernet",
"cooling": "None",
"computer_name": "127.0.0.1",
"max_frame_rate": "102",
"frame_rate_unit": "hertz",
"immersion": null,
"chroma": "Monochrome",
Expand Down Expand Up @@ -1050,7 +1047,7 @@
"data_interface": "Other",
"cooling": "Air",
"computer_name": null,
"max_frame_rate": null,

"frame_rate_unit": "hertz",
"immersion": null,
"chroma": null,
Expand Down
11 changes: 4 additions & 7 deletions tests/resources/dynamic_routing/mvr_rig.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"describedBy": "https://raw.githubusercontent.com/AllenNeuralDynamics/aind-data-schema/main/src/aind_data_schema/core/rig.py",
"schema_version": "0.3.8",
"schema_version": "0.5.1",
"rig_id": "327_NP2_240401",
"modification_date": "2024-04-01",
"mouse_platform": {
Expand Down Expand Up @@ -233,8 +233,7 @@
"data_interface": "Ethernet",
"cooling": "None",
"computer_name": "127.0.0.1",
"max_frame_rate": "102",
"frame_rate_unit": "hertz",
"frame_rate_unit": "hertz",
"immersion": null,
"chroma": "Monochrome",
"sensor_width": 7400,
Expand Down Expand Up @@ -380,7 +379,6 @@
"data_interface": "Ethernet",
"cooling": "None",
"computer_name": "127.0.0.1",
"max_frame_rate": "102",
"frame_rate_unit": "hertz",
"immersion": null,
"chroma": "Monochrome",
Expand Down Expand Up @@ -524,8 +522,7 @@
"data_interface": "Ethernet",
"cooling": "None",
"computer_name": "127.0.0.1",
"max_frame_rate": "102",
"frame_rate_unit": "hertz",
"frame_rate_unit": "hertz",
"immersion": null,
"chroma": "Monochrome",
"sensor_width": 7400,
Expand Down Expand Up @@ -1065,7 +1062,7 @@
"data_interface": "Other",
"cooling": "Air",
"computer_name": null,
"max_frame_rate": null,

"frame_rate_unit": "hertz",
"immersion": null,
"chroma": null,
Expand Down
7 changes: 2 additions & 5 deletions tests/resources/dynamic_routing/sync_rig.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"describedBy": "https://raw.githubusercontent.com/AllenNeuralDynamics/aind-data-schema/main/src/aind_data_schema/core/rig.py",
"schema_version": "0.3.8",
"schema_version": "0.5.1",
"rig_id": "327_NP2_240401",
"modification_date": "2024-04-01",
"mouse_platform": {
Expand Down Expand Up @@ -233,7 +233,6 @@
"data_interface": "Ethernet",
"cooling": "None",
"computer_name": "127.0.0.1",
"max_frame_rate": "102",
"frame_rate_unit": "hertz",
"immersion": null,
"chroma": "Monochrome",
Expand Down Expand Up @@ -375,7 +374,6 @@
"data_interface": "Ethernet",
"cooling": "None",
"computer_name": "127.0.0.1",
"max_frame_rate": "102",
"frame_rate_unit": "hertz",
"immersion": null,
"chroma": "Monochrome",
Expand Down Expand Up @@ -514,7 +512,6 @@
"data_interface": "Ethernet",
"cooling": "None",
"computer_name": "127.0.0.1",
"max_frame_rate": "102",
"frame_rate_unit": "hertz",
"immersion": null,
"chroma": "Monochrome",
Expand Down Expand Up @@ -1050,7 +1047,7 @@
"data_interface": "Other",
"cooling": "Air",
"computer_name": null,
"max_frame_rate": null,

"frame_rate_unit": "hertz",
"immersion": null,
"chroma": null,
Expand Down
2 changes: 1 addition & 1 deletion tests/resources/fip/000000_ophys_session.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"describedBy": "https://raw.githubusercontent.com/AllenNeuralDynamics/aind-data-schema/main/src/aind_data_schema/core/session.py",
"schema_version": "0.2.6",
"schema_version": "0.3.1",
"protocol_id": [],
"experimenter_full_name": [
"Don Key"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@
"data_interface": "Coax",
"cooling": "Air",
"computer_name": null,
"max_frame_rate": null,

"frame_rate_unit": "hertz",
"immersion": null,
"chroma": null,
Expand Down
3 changes: 2 additions & 1 deletion tests/resources/mesoscope/expected_session.json
Original file line number Diff line number Diff line change
@@ -1,13 +1,14 @@
{
"describedBy": "https://raw.githubusercontent.com/AllenNeuralDynamics/aind-data-schema/main/src/aind_data_schema/core/session.py",
"schema_version": "0.2.6",
"schema_version": "0.3.1",
"protocol_id": [],
"experimenter_full_name": [
"John Doe"
],
"session_start_time": "2024-02-22T15:30:00Z",
"session_end_time": "2024-02-22T17:30:00Z",
"session_type": "Mesoscope",
"headframe_registration": None,
"iacuc_protocol": "12345",
"rig_id": "MESO.1",
"calibrations": [],
Expand Down
2 changes: 1 addition & 1 deletion tests/resources/open_ephys/ephys_session.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"describedBy": "https://raw.githubusercontent.com/AllenNeuralDynamics/aind-data-schema/main/src/aind_data_schema/core/session.py",
"schema_version": "0.2.6",
"schema_version": "0.3.1",
"protocol_id": [],
"experimenter_full_name": [
"Al Dente"
Expand Down
13 changes: 5 additions & 8 deletions tests/resources/open_ephys/open-ephys-inferred_rig.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"describedBy": "https://raw.githubusercontent.com/AllenNeuralDynamics/aind-data-schema/main/src/aind_data_schema/core/rig.py",
"schema_version": "0.3.8",
"schema_version": "0.5.1",
"rig_id": "327_NP2_240401",
"modification_date": "2024-04-01",
"mouse_platform": {
Expand Down Expand Up @@ -233,8 +233,7 @@
"data_interface": "Ethernet",
"cooling": "None",
"computer_name": "127.0.0.1",
"max_frame_rate": "102",
"frame_rate_unit": "hertz",
"frame_rate_unit": "hertz",
"immersion": null,
"chroma": "Monochrome",
"sensor_width": 7400,
Expand Down Expand Up @@ -375,8 +374,7 @@
"data_interface": "Ethernet",
"cooling": "None",
"computer_name": "127.0.0.1",
"max_frame_rate": "102",
"frame_rate_unit": "hertz",
"frame_rate_unit": "hertz",
"immersion": null,
"chroma": "Monochrome",
"sensor_width": 7400,
Expand Down Expand Up @@ -514,8 +512,7 @@
"data_interface": "Ethernet",
"cooling": "None",
"computer_name": "127.0.0.1",
"max_frame_rate": "102",
"frame_rate_unit": "hertz",
"frame_rate_unit": "hertz",
"immersion": null,
"chroma": "Monochrome",
"sensor_width": 7400,
Expand Down Expand Up @@ -1050,7 +1047,7 @@
"data_interface": "Other",
"cooling": "Air",
"computer_name": null,
"max_frame_rate": null,

"frame_rate_unit": "hertz",
"immersion": null,
"chroma": null,
Expand Down
13 changes: 5 additions & 8 deletions tests/resources/open_ephys/open-ephys_rig.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"describedBy": "https://raw.githubusercontent.com/AllenNeuralDynamics/aind-data-schema/main/src/aind_data_schema/core/rig.py",
"schema_version": "0.3.8",
"schema_version": "0.5.1",
"rig_id": "327_NP2_240401",
"modification_date": "2024-04-01",
"mouse_platform": {
Expand Down Expand Up @@ -233,8 +233,7 @@
"data_interface": "Ethernet",
"cooling": "None",
"computer_name": "127.0.0.1",
"max_frame_rate": "102",
"frame_rate_unit": "hertz",
"frame_rate_unit": "hertz",
"immersion": null,
"chroma": "Monochrome",
"sensor_width": 7400,
Expand Down Expand Up @@ -375,8 +374,7 @@
"data_interface": "Ethernet",
"cooling": "None",
"computer_name": "127.0.0.1",
"max_frame_rate": "102",
"frame_rate_unit": "hertz",
"frame_rate_unit": "hertz",
"immersion": null,
"chroma": "Monochrome",
"sensor_width": 7400,
Expand Down Expand Up @@ -514,8 +512,7 @@
"data_interface": "Ethernet",
"cooling": "None",
"computer_name": "127.0.0.1",
"max_frame_rate": "102",
"frame_rate_unit": "hertz",
"frame_rate_unit": "hertz",
"immersion": null,
"chroma": "Monochrome",
"sensor_width": 7400,
Expand Down Expand Up @@ -1050,7 +1047,7 @@
"data_interface": "Other",
"cooling": "Air",
"computer_name": null,
"max_frame_rate": null,

"frame_rate_unit": "hertz",
"immersion": null,
"chroma": null,
Expand Down
Loading
Loading