Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
W
wela
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Swain Lab
wela
Commits
655a07e5
Commit
655a07e5
authored
1 year ago
by
pswain
Browse files
Options
Downloads
Patches
Plain Diff
made compatible with no chainer in aliby
parent
18837579
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
dataloader.py
+6
-7
6 additions, 7 deletions
dataloader.py
with
6 additions
and
7 deletions
dataloader.py
+
6
−
7
View file @
655a07e5
...
@@ -7,7 +7,7 @@ import pandas as pd
...
@@ -7,7 +7,7 @@ import pandas as pd
from
wela.correct_buds
import
correct_buds
from
wela.correct_buds
import
correct_buds
try
:
try
:
from
postprocessor.grouper
import
Name
Grouper
from
postprocessor.grouper
import
Grouper
except
ModuleNotFoundError
:
except
ModuleNotFoundError
:
print
(
"
Can only load tsv files - cannot find postprocessor
"
)
print
(
"
Can only load tsv files - cannot find postprocessor
"
)
...
@@ -137,7 +137,7 @@ class dataloader:
...
@@ -137,7 +137,7 @@ class dataloader:
def
get_grouper
(
self
,
dataname
):
def
get_grouper
(
self
,
dataname
):
"""
"""
Return an instance of
Name
Grouper.
Return an instance of Grouper.
Arguments
Arguments
---------
---------
...
@@ -146,11 +146,11 @@ class dataloader:
...
@@ -146,11 +146,11 @@ class dataloader:
Returns
Returns
-------
-------
grouper: instance of
Name
Grouper
grouper: instance of Grouper
"""
"""
if
dataname
[
-
4
:]
==
"
.tsv
"
:
if
dataname
[
-
4
:]
==
"
.tsv
"
:
dataname
=
dataname
[:
-
4
]
dataname
=
dataname
[:
-
4
]
grouper
=
Name
Grouper
(
self
.
h5dirpath
/
dataname
)
grouper
=
Grouper
(
self
.
h5dirpath
/
dataname
)
return
grouper
return
grouper
def
load
(
def
load
(
...
@@ -230,7 +230,7 @@ class dataloader:
...
@@ -230,7 +230,7 @@ class dataloader:
for
signal
in
grouper
.
available
:
for
signal
in
grouper
.
available
:
print
(
"
"
,
signal
)
print
(
"
"
,
signal
)
# find time interval between images
# find time interval between images
self
.
dt
=
grouper
.
tinterval
s
self
.
dt
=
grouper
.
tinterval
# get key index for choosing cells
# get key index for choosing cells
key_index_path
=
self
.
a2g_dict
[
key_index
]
key_index_path
=
self
.
a2g_dict
[
key_index
]
key_index
=
self
.
get_key_index
(
grouper
,
key_index_path
,
cutoff
)
key_index
=
self
.
get_key_index
(
grouper
,
key_index_path
,
cutoff
)
...
@@ -426,8 +426,7 @@ class dataloader:
...
@@ -426,8 +426,7 @@ class dataloader:
@property
@property
def
revert_df
(
self
):
def
revert_df
(
self
):
"""
"""
Convert the
'
id
'
column into the standard columns used by aliby
Convert the
'
id
'
column into aliby
'
s standard columns and vice versa.
and vice versa.
These columns are
'
position
'
,
'
trap
'
, and
'
cell_label
'
, either
These columns are
'
position
'
,
'
trap
'
, and
'
cell_label
'
, either
adding three columns to the .df data frame or removing three
adding three columns to the .df data frame or removing three
...
...
This diff is collapsed.
Click to expand it.
Arin Wongprommoon
@s1947236
mentioned in issue
#2
·
1 year ago
mentioned in issue
#2
mentioned in issue #2
Toggle commit list
Arin Wongprommoon
@s1947236
mentioned in commit
ee8c4d5d
·
1 year ago
mentioned in commit
ee8c4d5d
mentioned in commit ee8c4d5db123cc9844fc9a0ec0a1e8043a774506
Toggle commit list
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment