Coder Social home page Coder Social logo

tierpsy / tierpsy-tracker Goto Github PK

View Code? Open in Web Editor NEW

This project forked from ver228/tierpsy-tracker

17.0 3.0 17.0 353.71 MB

Multi-Worm Behaviour Tracker. README here:

Home Page: https://github.com/Tierpsy/tierpsy-tracker/blob/development/README.md

License: MIT License

Python 94.97% Shell 0.38% C 0.68% Makefile 0.05% Batchfile 0.20% Cython 3.42% Dockerfile 0.13% PowerShell 0.18%

tierpsy-tracker's Introduction

Tierpsy Tracker

Tierpsy Tracker is a multi-animal tracker developed in the MRC-LMS Behavioural Phenomics Lab at Imperial College London. The project combines the throughput of multiworm tracking with the resolution of single worm tracking, which means you can extract detailed phenotypic fingerprints from more animals. A large field of view also makes it possible to analyse collective behaviours that depend on animal interactions. The code is open source and extensible and we have ongoing projects using the tracker to analyse fish, Drosophila larvae, and fluorescently labelled worms.

For more details see the installation instructions section.

Publications

  • Javer, A., Currie, M., Lee, C.W. et al. An open-source platform for analyzing and sharing worm-behavior data. Nat Methods 15, 645–646 (2018). https://doi.org/10.1038/s41592-018-0112-1

  • Javer, A., Ripoll-Sánchez, L., and Brown, A.E.X. Powerful and interpretable behavioural features for quantitative phenotyping of Caenorhabditis elegans. Phil. Trans. R. Soc. B 373: 20170375 (2018). http://doi.org/10.1098/rstb.2017.0375

tierpsy-tracker's People

Contributors

em812 avatar ilbarlow avatar jgnieto avatar ljschumacher avatar luigiferiani avatar ver228 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

tierpsy-tracker's Issues

x and y coordinates

HI

I am using tierpsy tracker to analyze some videos of worms' movement and their possible location after chemical treatments in a microfluidic maze. I am interested to know that is it possible to know the xy coordinates of the worms using tierpsy tracker. I didn't see the xy coordinates in the output file. If it is possible, please let me know the process to calculate the x y coordinates.

Thanks

installation on linux (ubuntu 18.04)

I could not get a working installation on linux using the commands described in the documentation, which are as follows:

git clone https://github.com/Tierpsy/tierpsy-tracker
cd tierpsy-tracker
conda create -n tierpsy #[optional]
conda activate tierpsy #[optional]
conda install --file requirements.txt
pip install -e .

Instead, what I found to work was replacing lines 3-5 in that command with the following:

conda env create -n tierpsy -f tierpsy_linux.yml
conda activate tierpsy

where I generated the file tierpsy_linux.yml myself, which contains the following:

name: tierpsy
channels:
  - conda-forge
  - defaults
  - pytorch  
  - anaconda
dependencies:
  - cython
  - ffmpeg
  - keras
  - opencv
  - matplotlib
  - numba
  - numpy>=1.14
  - pandas
  - pyqt
  - pytables
  - pytorch
  - requests
  - scikit-image  
  - scikit-learn
  - scipy
  - statsmodels
  - tensorflow
  - torchvision
  - tqdm

Split_fov

Hi!

Thank you for your the code, it is really helpful.

I am currently trying to use the split_fov option. We have a single Kastl machine (from loopbio), and using square 96-well plates as used in Barlow et al., 2022.

I saw the the 'HYDRA_96WP_UPRIGHT.json' file in the 'tierpsy\extras\splitfov_param_files' dir specifies serial numbers of cameras and also number of HYDRA. Since we have only one hydra and different serial numbers for the six cameras, I edited and saved a new json file (same dir). When creating the parameters file for the analysis I pick 'custom' under MWP_mapping and provide the path in the relevant box.
When I try to analyze, first it is extracting video metadata, and when done counting number of frames, I get this:

loading json C:\Users-----\Tierpsy\tierpsy-tracker\tierpsy\extras\splitfov_param_files\MOS_96WP_UPRIGHT.json for split fov
ERROR:
RuntimeError: The map-like callable must be of the form f(func, iterable), returning a sequence of numbers the same length as 'iterable'
Traceback (most recent call last):
File "C:\Users----\miniconda3\envs\tierpsy\lib\site-packages\scipy\optimize_differentialevolution.py", line 789, in _calculate_population_energies
parameters_pop[0:nfevs]))
File "C:\Users----\miniconda3\envs\tierpsy\lib\site-packages\scipy\optimize_differentialevolution.py", line 1028, in call
return self.f(x, *self.args)
File "c:\users----\tierpsy\tierpsy-tracker\tierpsy\analysis\split_fov\FOVMultiWellsSplitter.py", line 320, in fun_to_minimise
template_shape=self.well_shape,
File "c:\users----\tierpsy\tierpsy-tracker\tierpsy\analysis\split_fov\helper.py", line 357, in simulate_wells_lattice
dtype_out='float')
File "c:\users----\tierpsy\tierpsy-tracker\tierpsy\analysis\split_fov\helper.py", line 234, in make_square_template
x = np.linspace(-0.5, 0.5, n_pxls)
File "<array_function internals>", line 6, in linspace
File "C:\Users----\miniconda3\envs\tierpsy\lib\site-packages\numpy\core\function_base.py", line 124, in linspace
raise ValueError("Number of samples, %s, must be non-negative." % num)
ValueError: Number of samples, -2379, must be non-negative.

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "c:\users----\tierpsy\tierpsy-tracker\tierpsy\processing\ProcessWorker.py", line 108, in
ProcessWorker(**args, cmd_original = subprocess.list2cmdline(sys.argv))
File "c:\users----\tierpsy\tierpsy-tracker\tierpsy\processing\ProcessWorker.py", line 38, in init
self.execAllPoints()
File "c:\users----\tierpsy\tierpsy-tracker\tierpsy\processing\ProcessWorker.py", line 66, in execAllPoints
cmd_original = self.cmd_original)
File "c:\users----\tierpsy\tierpsy-tracker\tierpsy\processing\trackProvenance.py", line 28, in execThisPoint
func(**argkws)
File "c:\users----\tierpsy\tierpsy-tracker\tierpsy\analysis\compress\processVideo.py", line 142, in processVideo
compressVideo(video_file, masked_image_file, **compress_vid_param)
File "c:\users----\tierpsy\tierpsy-tracker\tierpsy\analysis\compress\compressVideo.py", line 318, in compressVideo
wells_map=mwp_map
File "c:\users----\tierpsy\tierpsy-tracker\tierpsy\analysis\split_fov\FOVMultiWellsSplitter.py", line 133, in init
self.constructor_from_image(fname_or_img)
File "c:\users----\tierpsy\tierpsy-tracker\tierpsy\analysis\split_fov\FOVMultiWellsSplitter.py", line 178, in constructor_from_image
self.find_wells_on_grid()
File "c:\users-----\tierpsy\tierpsy-tracker\tierpsy\analysis\split_fov\FOVMultiWellsSplitter.py", line 344, in find_wells_on_grid
fun_to_minimise, bounds, polish=True)
File "C:\Users----\miniconda3\envs\tierpsy\lib\site-packages\scipy\optimize_differentialevolution.py", line 276, in differential_evolution
ret = solver.solve()
File "C:\Users----\miniconda3\envs\tierpsy\lib\site-packages\scipy\optimize_differentialevolution.py", line 688, in solve
self.population)
File "C:\Users----\miniconda3\envs\tierpsy\lib\site-packages\scipy\optimize_differentialevolution.py", line 794, in _calculate_population_energies
raise RuntimeError("The map-like callable must be of the"
RuntimeError: The map-like callable must be of the form f(func, iterable), returning a sequence of numbers the same length as 'iterable'
"C:\Users----\miniconda3\envs\tierpsy\python.exe" "c:\users-----\tierpsy\tierpsy-tracker\tierpsy\processing\ProcessWorker.py" "C:\Users----\Tracker Files test\96-well plates agar\agar- 10 fps\kk_031023_96well_agar_10fps_20231003_150608.24536747\kk_031023_96well_agar_10fps_20231003_150608.24536747.mp4" --masks_dir "C:\Users----\Tmp\MaskedVideos" --results_dir "C:\Users----\Tmp\Results" --json_file "C:\Users----\Tracker Files test\96-well plates agar\agar - 10 fps\kk_031023_96well_agar_10fps_20231003_150608.24536747\kk_031023_96well_agar_10fps_20231003_150608.24536747.json" --analysis_checkpoints "COMPRESS" "TRAJ_CREATE" "TRAJ_JOIN" "SKE_INIT" "BLOB_FEATS" "SKE_CREATE" "SKE_FILT" "SKE_ORIENT" "INT_PROFILE" "INT_SKE_ORIENT" "FEAT_INIT" "FEAT_TIERPSY"


Tasks: 1 finished, 0 remaining. Total_time 0:01:41.


Please, any help to make it work properly will be much appreciated. I want to use the well annotator program as well.
Thanks in advance,

Asaf

Questions operating Tierpsy

Dear all,
We installed Tierpsy 1.5.1 on a Win10 PC, and are interested in using it to analyze our experiments with multiple worms. At this point we are mainly interested with trajectories and speeds, although we plan to look also into skeleton movements in the future. Trying Tierpsy using the comprehensive tutorial, we nonetheless have a few principle questions:

  1. There are 13 Analysis Types available in the Set Parameters window, yet only 6 in the table in the HOWTO tutorial. It is not clear which we should use at this point.
  2. In the Tierpsy Tracker Viewer, the operation is not entirely clear from the movies and the tutorial. For example, after several manual corrections we still end up with incorrect trajectories and "jumps" when two worms or more pass closely together.
  3. It is not clear if we can use the WCON Viewer, or any other software, to view and analyze trajectories and speeds in our result files.
  4. In order to explore and analyze trajectories and speeds on our own, we tried to import the HDF5 datasets in either Python (conda packages) or Wolfram Mathematica (which supports HDF5 import). However, in both case we get some issues with NaN values and unsupported bitfield datatype, possibly because of incorrect results due to questions 1 and 2.
    Thanks in advance!

OSError: [WinError 126] prevents batch processing

Hi @luigiferiani,

I pulled the latest version of Tierpsy and followed the installation from source instructions with no problems aside from fixing the Qt plugin path error as I described here. I can set parameters, but when I attempt to batch process a folder of videos, I encounter this error:

Traceback (most recent call last):
  File "c:\repos\tierpsy-tracker\tierpsy\gui\AnalysisProgress.py", line 62, in run
    self.worker_fun(**self.worker_args)
  File "c:\repos\tierpsy-tracker\tierpsy\processing\processMultipleFilesFun.py", line 129, in processMultipleFilesFun
    is_debug = is_debug)
OSError: [WinError 126] The specified module could not be found

In the corresponding processMultipleFilesFun.py file, line 129 is part of this code block:

if unmet_requirements:
        files_checker._printUnmetReq()
elif not only_summary:
    RunMultiCMD(
        cmd_list,
        local_obj = ProcessLocalParser,
        max_num_process = max_num_process,
        refresh_time = refresh_time,
        is_debug = is_debug)

The RunMultiCMD function comes from this import:

from tierpsy.processing.run_multi_cmd import RunMultiCMD

The run_multi_cmd.py file is in the same directory as processMultipleFilesFun.py and contains a lengthy RunMultiCMD function:

def RunMultiCMD(cmd_list,
                local_obj='',
                max_num_process=3,
                refresh_time=10,
                is_debug = True):
    '''Start different process using the command is cmd_list'''


    start_obj = partial(StartProcess, local_obj=local_obj, is_debug=is_debug)
# and so on...

StackOverflow has a question with over 100k views about WinError126. There seem to be a wide variety of possible causes, so I'm not sure what solution to try.

Any idea why this error is occurring?

Set Parameters crashes after enabling background subtraction

Hi @luigiferiani,

I installed Tierpsy from source yesterday on my Windows 11 laptop. I have a problem in the "Set Parameters" window in the GUI. To reproduce, I select a video file, then click "Background" and check "Subtract Background," setting background buffer size = 250 and gap between frames = 25 like in the tutorial; then if I click "Play" the window becomes mostly irresponsive to user input (for example, switching back to the "Mask" section can make the window stop responding).

Also, the window stops responding briefly (but then resumes working) if I click the "Update Background" button. It appears that this button applies the background subtraction (although I can't find any mention of it in the docs). Clicking "Play" after "Update Background" still makes the window nearly impossible to use.

Perhaps the issue is that running "Play" with background subtraction is computationally expensive, so the computer can only play the video at a rate of 1 frame per >3 seconds. This makes sense since sometimes I can see the frame count increasing.

Am I using background subtraction incorrectly?

As a side question, where can I find info about choosing appropriate parameter settings (background buffer size and gap between frames) for background subtraction?

Too many worms filtered out

Hi,

I have videos with several worms moving, the masks are great but more than half of the worms are not tracked. I have tried many different parameters, but the results are usually the same, only worms_bw_thresh_factor had an influence but did not really solve the problem either.

Here is an example of video and results : https://drive.switch.ch/index.php/s/Hkn1RaQ08LvwjPd

Would you have an idea if there could be a parameter that would screw up the result and filter out so many worms from tracking ?

Thanks for any kind of help :)

Screenshot from 2022-05-05 15-08-49

batch processing multiple files step not picking up files in directory

Hi! Thank you so much for creating this very useful tracker! I have been using it for about 1 month now and all has been working smoothly however when I tried to process more videos in the "Batch Processing Multiple Files" step after setting the parameters, as I normally do, it is not sensing that there are files in the directory that I am assigning it. I have changed nothing about what I'm doing so I'm not sure what changed. I have attached an image of what the Analysis Progress looks like, it should say that there is "1 total file to be processed". I would really appreciate your help with this!

tierpsyhelp

Thank you!

Can't find Qt platform plugin after install from source

Hello @luigiferiani,

I downloaded the repository from ZIP, then successfully ran
conda env create -f tierpsy_windows.yml #[Windows 10]
conda activate tierpsy
pip install -e .
as described in the instructions.

However, when I run tierpsy_gui, the following error appears:

qt.qpa.plugin: Could not find the Qt platform plugin "windows" in ""
This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem.

This is on a Dell XPS 13 with Windows 11. Any idea why this is happening?

extracting frequency data from featuresN files

Hi,
I am a PhD candidate using tierpsy for my research. It is a great tool ! . I had an older version of tierpsy that generated features.hdf5 files and allowed me to extract undulation frequency of my animals. I switched to the new version an I am unable to get frequency data from the features N files. Was frequency removed from the analysis? I have also tried with running the analysis in openworm mode but I have been unsuccessful too.

Any help or suggestion would be useful.

Skeleton is NaN

I have tried to analyze a video using the Tierpsy Tracker, and it works fine, but when I look at the output file video_skeletons.hdf5, all contents of skeleton are nan. Why is this? I need to use these contents with WormPose.

can't get tierpsy tracker to work on mac or pc, possibly can't get good install?

Hi Folks,
We would love to be able to use (and cite!!) your tool tierpsy tracker to analyze locomotion defects in our C. elegans mutants, but can't seem to get in to work. We've followed instructions for installation and at first, tierpsy would crash instantly when trying to open a test video to set parameters. When that didn't work, we tried following instructions in some of the past issue posts. This got us to be able to set parameters, and we could run the batch processing. Batch processing would create the folders, but no analysis files ever appear. The progress bar in the window that opens reaches 100% but the window never closes, so maybe it is not finishing.
We suspect that there is now some incompatibility of the different versions of anaconda, python, etc with tierpsy. However, I am not a programmer and can't troubleshoot this very well. If possible, we would love help! Perhaps you could update the installation to use only compatible versions? My apologies for my shortcomings in computer science--I'm mostly a geneticist who would love to be able to use this tool without knowing so much about what's "under the hood." Thanks very much!!!

Docker installation doesn't work on windows 10 (requires windows 10 pro)

Hi!
I'm trying to install the Docker on my PC, which has windows 10, and the installation fails with the note "one prerequisite is not fulfilled: Docker Desktop requires Windows 10 Pro/Enterprise/Home (18363+)."
Is it possible to make Docker installation work on windows 10, not pro?

I really appreciate any help you can provide,
Lada Pechuk

Comparing /blob_features in *_skeletons.hdf5 and *_featuresN.hdf5

Hi @luigiferiani,

Quick question about the differences between these two files.

The documentation's "Software Explanation" says that *_skeletons.hdf5 comes before filtering and *_featuresN.hdf5 comes after filtering. Quoting the latter link:

FEAT_INIT
The smooth module in tierpsy features is used to smooth the skeletons over both time and space and to interpolate between small gaps of unskeletonized frames. As well to create the corresponding versions of the tables /blob_features, /trajectories_data and /food_cnt_coord(if available) from the basename_skeletons.hdf5.

Are these "corresponding versions" simply duplicates? The documentation's "Output Files" section says that /trajectories_data is the same as the original in *_skeletons.hdf5, but uses "the video timestamp to drop duplicated or interpolate missing frames," so it's not a duplicate. But /blob_features is the "same as /blob_features in basename_skeletons.hdf5." Does /blob_features come after the same filtering and interpolating steps as /trajectories_data?

On Windows, Tierpsy often hangs after finishing to analyse some videos, does not move on to the next ones

Hi @luigiferiani,

I originally posted in an older issue, but it was closed now, so I wanted to make sure that you will see my comment.
Regarding the details you asked for:

  • This is Tierpsy version 1.5.1, windows 10.

  • I used 3 different machines with slightly different specs - it happened in all 3.
    for example- one computer specs:
    Intel i7-6700CPU 3.4 GHz with 32 GB (RAM), 64bit.

  • The masked videos are between 250 to 700 Mb (most around ~450), the results files (except the 'intensities') range between 40-270MB, the 'intensities' result files are lighter - 3-30MB.

  • Because we had to analyze many files, I splitted to many computers and locations, so I think I tried to analyze files that were located on desktop, also some that were located in an external hard drive & some that were in a shared dropbox folder :)

  • The dialog box looks like that:

image

  • I do want to mention that my original videos are in avi format, captured by the WormLab MBF Bioscience software.

I don't mind sharing one file - can I send by e-mail?
Thanks,
Asaf

Originally posted by @asafgat in #53 (comment)

Getting timestamp from the hdf5 file

Hey all.

I have an hdf5 file generated by tierpsy loaded in Python:

import pandas as pd
file_location = "<filename>.hdf5"
f = pd.HDFStore(file_location)

I'm looking to work directly with the timeseries data. In particular, I care about the worm index, timestamp, and motion modes:

motion_modes = f.get("features_timeseries")[["worm_index", "timestamp", "motion_modes"]]

I'd like to figure out the frames-per-second for the particular video that generated this HDF5 file. In particular, I'd like to average the motion-mode to some kind of "movement-per-second" metric, with the motion mode averaged for all rows for a particular worm in a given second.

Is there an easy way to pull out the length of the video, or even better, the frames-per-second? the frames used in "timestamp" aren't very useful to me if I don't have a time-conversion.

Can't get the boxes after processing

Hey all,

Thanks for sharing this amazing code. I am trying to track single worms and to get their trajectories and speed. I can get good parameters for the mask so that the mask correspond well to the worm, but after processing there is no box around the worm and I cannot plot anything.

Here is the video I am trying to analyze, the parameters and outputs

I am running the last version of the development branch on Ubuntu 20.04

Am I missing something or are there some other parameters to modify ?

Here is what is happening

Screencast.mp4

At the end it crashes with the following message

Traceback (most recent call last):
File "/home/matthieu/tierpsy-tracker/tierpsy/gui/MWTrackerViewer.py", line 942, in show_plot
self.update_plot()
File "/home/matthieu/tierpsy-tracker/tierpsy/gui/MWTrackerViewer.py", line 946, in update_plot
self.plotter.plot(self.current_worm_index, self.feat_column)
File "/home/matthieu/tierpsy-tracker/tierpsy/gui/PlotFeatures.py", line 132, in plot
func(worm_index, feature)
File "/home/matthieu/tierpsy-tracker/tierpsy/gui/PlotFeatures.py", line 140, in _plot_single_timeseries
worm_data = self.traj_worm_index_grouped.get_group(worm_index)
File "/home/matthieu/anaconda3/envs/tierpsy/lib/python3.6/site-packages/pandas/core/groupby/groupby.py", line 680, in get_group
raise KeyError(name)
KeyError: None
[1] 1160322 abort (core dumped) tierpsy_gui

Thanks a lot.

packages conflicts in source installation on Windows 11

Hi!
I cloned the repo successfully but when I tried to create the environment with

conda env create -f tierpsy_windows.yml

I got an error

Could not solve for environment specs
The following packages are incompatible
├─ h5py 2.10.0**  is installable with the potential options
│  ├─ h5py 2.10.0 would require
│  │  └─ python_abi * *_cp36m, which can be installed;
│  ├─ h5py 2.10.0 would require
│  │  └─ hdf5 >=1.10.6,<1.10.7.0a0 , which can be installed;
│  ├─ h5py 2.10.0 would require
│  │  └─ python_abi * *_cp37m, which can be installed;
│  ├─ h5py 2.10.0 would require
│  │  └─ python_abi * *_cp38, which can be installed;
│  └─ h5py 2.10.0 would require
│     └─ hdf5 >=1.10.4,<1.10.5.0a0 , which can be installed;
├─ hdf5 1.10.5**  is not installable because it conflicts with any installable versions previously reported;
├─ openssl 1.1.1g**  is requested and can be installed;
├─ python 3.6.10**  is requested and can be installed;
├─ python_abi 3.6**  is not installable because it conflicts with any installable versions previously reported;
├─ pytorch 1.5.0**  is not installable because it requires
│  └─ python >=3.7,<3.8.0a0  but there are no viable options
│     ├─ python [3.7.0|3.7.1|...|3.7.9] conflicts with any installable versions previously reported;
│     ├─ python [3.7.10|3.7.12] would require
│     │  └─ python_abi 3.7 *_pypy37_pp73, which conflicts with any installable versions previously reported;
│     ├─ python 3.7.10 would require
│     │  └─ openssl >=1.1.1j,<1.1.2a , which conflicts with any installable versions previously reported;
│     ├─ python [3.7.10|3.7.12] would require
│     │  └─ openssl >=1.1.1l,<1.1.2a , which conflicts with any installable versions previously reported;
│     ├─ python [3.7.10|3.7.12] would require
│     │  └─ openssl >=3.0.0,<4.0a0 , which conflicts with any installable versions previously reported;
│     ├─ python [3.7.5|3.7.9] would require
│     │  └─ openssl >=1.1.1i,<1.1.2a , which conflicts with any installable versions previously reported;
│     ├─ python [3.7.8|3.7.9] would require
│     │  └─ openssl >=1.1.1h,<1.1.2a , which conflicts with any installable versions previously reported;
│     ├─ python 3.7.11 would require
│     │  └─ openssl >=1.1.1k,<1.1.2a , which conflicts with any installable versions previously reported;
│     ├─ python 3.7.13 would require
│     │  └─ openssl >=1.1.1n,<1.1.2a , which conflicts with any installable versions previously reported;
│     ├─ python 3.7.13 would require
│     │  └─ openssl >=1.1.1q,<1.1.2a , which conflicts with any installable versions previously reported;
│     └─ python [3.7.15|3.7.16] would require
│        └─ openssl >=1.1.1s,<1.1.2a , which conflicts with any installable versions previously reported;
└─ torchvision 0.6.0**  does not exist (perhaps a typo or a missing channel).

Removing the versions constrains from tierpsy_windows.yml file resulted in issues with finding Qt plugin:

This application failed to start because no Qt platform plugin could be initialized.```  

I'm using 
conda 23.10.0
pip 23.2.1
on Windows 11

Do you have any suggestions how to solve this?

Export cropped images for a single worm

Hi,

Is it possible to export every single cropped images for a single worm shown in the video? For example, if a video with 1000 frames contains 5 worms and I would like to have 1000 cropped images that only show a single worm for each worms, how do I export the 5000 images? Is it something built in the GUI or I have do it with command lines and specific functions?

Thanks,

missing documentation regarding command line use

The documentation says there is an option to use tierpsy tracker on the command line with the following:

python cmd_scripts/processMultipleFiles.py -h

However, I cannot find this file anywhere. Probably the documentation needs to be updated. Is command line use still supported? If so can you please describe the usage? Thank you!

HDF5 file unable to be created/opened

I met this issue during Batch Processing Multiple Files, using both the example files as well as my own local files (in .avi and .mp4 format)
ERROR:
Unable to open/create file '/home/tierpsy_user/Tmp/MaskedVideos/cam2+ob1-1.hdf5'
Traceback (most recent call last):
File "/tierpsy-tracker/tierpsy/processing/ProcessWorker.py", line 108, in
ProcessWorker(**args, cmd_original = subprocess.list2cmdline(sys.argv))
File "/tierpsy-tracker/tierpsy/processing/ProcessWorker.py", line 38, in init
self.execAllPoints()
File "/tierpsy-tracker/tierpsy/processing/ProcessWorker.py", line 66, in execAllPoints
cmd_original = self.cmd_original)
File "/tierpsy-tracker/tierpsy/processing/trackProvenance.py", line 28, in execThisPoint
func(**argkws)
File "/tierpsy-tracker/tierpsy/analysis/compress/processVideo.py", line 142, in processVideo
compressVideo(video_file, masked_image_file, **compress_vid_param)
File "/tierpsy-tracker/tierpsy/analysis/compress/compressVideo.py", line 243, in compressVideo
save_full_interval = save_full_interval)
File "/tierpsy-tracker/tierpsy/helper/params/get_defaults.py", line 48, in compress_defaults
fps = _read_correct_fps(fname, expected_fps)
File "/tierpsy-tracker/tierpsy/helper/params/get_defaults.py", line 23, in _read_correct_fps
fps_out = read_unit_conversions(fname)[0]
File "/tierpsy-tracker/tierpsy/helper/params/read_attrs.py", line 188, in read_unit_conversions
reader = AttrReader(fname, dflt)
File "/tierpsy-tracker/tierpsy/helper/params/read_attrs.py", line 54, in init
self.field = self._find_field()
File "/tierpsy-tracker/tierpsy/helper/params/read_attrs.py", line 59, in _find_field
with tables.File(self.file_name, 'r') as fid:
File "/home/tierpsy_user/.local/lib/python3.6/site-packages/tables/file.py", line 778, in init
self._g_new(filename, mode, **params)
File "tables/hdf5extension.pyx", line 492, in tables.hdf5extension.File._g_new
tables.exceptions.HDF5ExtError: HDF5 error back trace

File "H5F.c", line 509, in H5Fopen
unable to open file
File "H5Fint.c", line 1400, in H5F__open
unable to open file
File "H5Fint.c", line 1615, in H5F_open
unable to lock the file
File "H5FD.c", line 1640, in H5FD_lock
driver lock request failed
File "H5FDsec2.c", line 941, in H5FD_sec2_lock
unable to lock file, errno = 11, error message = 'Resource temporarily unavailable'

End of HDF5 error back trace

I have checked the temporary dir box and all other processes have been ceased to prioritise this analysing process.

Thank you very much for the help!

Masking seems good but no skeleton

Hello, I've installed the Tierpsy tracker via Docker and its been working great! However, Im having issues with the skeletons. During set parameters, im able to see the mask of the worm well and also tweaked additional parameters to try to identify the worm better. However, no matter what i do, the tracker does not show me a single skeleton or shows me inaccurate skeletons. This might be because of the low res video quality (Sample below) Please kindly advise on which parameters I can change to help identify the worms better!

image

Thank you !

Cannot extract feature data or view plots (best parameters for low resolution videos?)

Hi there!

I'm trying to use Tierpsy Tracker to track multiple worms in a 640x480 recording. While I've been able to get good masks of the worms and bounding boxes surrounding them, I'm unable to extract any feature information of them, and in Viewer I'm unable to access any plots of the data.

Below is an image of what I'm describing:

image

The main parameters I've adjusted are not using the default pytorch NN (per reading other issues with similar problems), along with background subtraction, threshold, and dilation. I suspect this has to do with the low resolution nature of the recordings, but I'm not sure if the inability to extract feature information or view plots is because of parameters or user error.

Thank you!!

Sample video and parameters here.

Trouble Creating Skeletons for Single Worm

Hi,
My name is Nick, I am a researcher working in Dr. Hang Lu's group at Georgia Tech.

I am trying to process an AVI video of a single worm and it seems the program is unable to create a skeleton for this worm.
I have looked at the output HDF5 skeletons file and it seems that /plate_worms is populated with data that looks fine where /trajectories_data is empy. The feature HDF5 file is also empty. The worm is being masked perfectly. Your example data also works fine and gives skeletons and features.

I have played around with some of the parameters with no success, is there any parameters you think could be the issue?
I can send you some of out data via email if you would like.

Thank you,
Nick

metaclass conflict

Hi,

I have managed to successfully install tierpsy-tracker in Ubuntu 22.04. I am trying to figure out how to use it with some sample videos we have.

However, when I click "Start" to run the batch processing I see the following output.
I was wondering if this is a bug or perhaps something I set-up incorrectly.

Any feedback would be appreciated.

Checking file 1 of 1. Total time: 0:00:00
*********************************************
Finished to check files.
Total time elapsed 0:00:00
*********************************************

*********************************************
Commands to be executed.
*********************************************
'/home/kosmas/miniconda3/envs/tierpsy/bin/python3.6' '/home/kosmas/repositories/tierpsy-tracker/tierpsy/processing/ProcessLocal.py' '/storage/other_trackings/celegans/test_approach/data/900 uL 24 well-777-996.avi' --masks_dir '/storage/other_trackings/celegans/test_approach/data/MaskedVideos' --results_dir '/storage/other_trackings/celeganss/test_approach/data/Results' --tmp_mask_dir '/home/kosmas/Tmp/MaskedVideos/' --tmp_results_dir '/home/kosmas/Tmp/Results/' --json_file '' --analysis_checkpoints 'COMPRESS' 'TRAJ_CREATE' 'TRAJ_JOIN' 'SKE_INIT' 'BLOB_FEATS' 'SKE_CREATE' 'SKE_FILT' 'SKE_ORIENT' 'INT_PROFILE' 'INT_SKE_ORIENT' 'FEAT_INIT' 'FEAT_TIERPSY'
*********************************************

*********************************************
Analysis Summary
*********************************************
1	Unprocessed files.
0	Files whose analysis is incompleted.
0	Invalid source files.
0	Files that were succesfully finished.
*********************************************
1	Total files to be processed.
*********************************************
Traceback (most recent call last):
  File "/home/kosmas/repositories/tierpsy-tracker/tierpsy/gui/AnalysisProgress.py", line 62, in run
    self.worker_fun(**self.worker_args)
  File "/home/kosmas/repositories/tierpsy-tracker/tierpsy/processing/processMultipleFilesFun.py", line 129, in processMultipleFilesFun
    is_debug = is_debug)
TypeError: metaclass conflict: the metaclass of a derived class must be a (non-strict) subclass of the metaclasses of all its bases

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.