Skip to content

Commit

Permalink
bugs
Browse files Browse the repository at this point in the history
  • Loading branch information
ver228 committed Apr 13, 2016
1 parent cd91e96 commit 849120d
Show file tree
Hide file tree
Showing 6 changed files with 48 additions and 9 deletions.
2 changes: 1 addition & 1 deletion MWTracker/trackWorms/getWormTrajectories.py
Original file line number Diff line number Diff line change
Expand Up @@ -626,7 +626,7 @@ def joinTrajectories(trajectories_file, min_track_size = 50, \

#read the worm_index column, this is the index order that have to be conserved in the worm_index_joined column
worm_index = plate_worms.col('worm_index')
_worm_index_joined = joinDict2Index(worm_index, relations_dict, valid_indexes)
worm_index_joined = _joinDict2Index(worm_index, relations_dict, valid_indexes)

#add the result the column worm_index_joined
plate_worms.modify_column(colname = 'worm_index_joined', column = worm_index_joined)
Expand Down
39 changes: 39 additions & 0 deletions Tests/run_tests.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
EXAMPLES_DIR="/Users/ajaver/Google Drive/MWTracker_Example"
SCRIPT_DIR=/Users/ajaver/Documents/GitHub/Multiworm_Tracking/cmd_scripts

TEST1_DIR="$EXAMPLES_DIR/test_1"
TEST2_DIR="$EXAMPLES_DIR/test_2"
TEST3_DIR="$EXAMPLES_DIR/test_3"


function test1 {
echo "%%%% TEST1 %%%%"
chflags -R nouchg "$TEST1_DIR/MaskedVideos"
rm -Rf "$TEST1_DIR/MaskedVideos"
python3 "$SCRIPT_DIR/compressMultipleFiles.py" "$TEST1_DIR/RawVideos" "$TEST1_DIR/MaskedVideos"
}

function test2 {
echo "%%%% TEST2 %%%%"
chflags -R nouchg "$TEST2_DIR/MaskedVideos"
rm -Rf "$TEST2_DIR/MaskedVideos"

python3 "$SCRIPT_DIR/compressMultipleFiles.py" "$TEST2_DIR/RawVideos" "$TEST2_DIR/MaskedVideos" \
--json_file "$TEST2_DIR/test2.json" --pattern_include "*.avi"
}

function test3 {
echo "%%%% TEST3 %%%%"
rm -Rf "$TEST3_DIR/Results"
python3 "$SCRIPT_DIR/trackMultipleFiles.py" "$TEST3_DIR/MaskedVideos" --json_file "$TEST3_DIR/test3.json"
}

function clean_all {
rm -Rf "$TEST1_DIR/MaskedVideos"
rm -Rf "$TEST2_DIR/MaskedVideos"
rm -Rf "$TEST3_DIR/Results"
}

#test1
#test1
test3
4 changes: 2 additions & 2 deletions single_worm_db/compress_mac1.sh
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
python3 ~/Documents/GitHub/Multiworm_Tracking/cmd_scripts/compressMultipleFiles.py \
/Volumes/behavgenom_archive\$/thecus /Volumes/behavgenom_archive\$/MaskedVideos \
--json_file ~/Documents/GitHub/Multiworm_Tracking/JSON_singleworm/swimming.json \
--json_file ~/Documents/GitHub/Multiworm_Tracking/single_worm_db/JSON_singleworm/swimming.json \
--is_copy_video --is_single_worm --max_num_process 21 \
--videos_list ~/Documents/GitHub/Multiworm_Tracking/single_worm_db/videos_swimming_1

python3 ~/Documents/GitHub/Multiworm_Tracking/cmd_scripts/compressMultipleFiles.py \
/Volumes/behavgenom_archive\$/thecus /Volumes/behavgenom_archive\$/MaskedVideos \
--json_file ~/Documents/GitHub/Multiworm_Tracking/JSON_singleworm/on_food.json \
--json_file ~/Documents/GitHub/Multiworm_Tracking/single_worm_db/JSON_singleworm/on_food.json \
--is_copy_video --is_single_worm --max_num_process 21 \
--videos_list ~/Documents/GitHub/Multiworm_Tracking/single_worm_db/videos_agar_1

Expand Down
4 changes: 2 additions & 2 deletions single_worm_db/compress_mac2.sh
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
python3 ~/Documents/GitHub/Multiworm_Tracking/cmd_scripts/compressMultipleFiles.py \
/Volumes/behavgenom_archive\$/thecus /Volumes/behavgenom_archive\$/MaskedVideos \
--json_file ~/Documents/GitHub/Multiworm_Tracking/JSON_singleworm/swimming.json \
--json_file ~/Documents/GitHub/Multiworm_Tracking/single_worm_db/JSON_singleworm/swimming.json \
--is_copy_video --is_single_worm --max_num_process 24 \
--videos_list ~/Documents/GitHub/Multiworm_Tracking/single_worm_db/videos_swimming_2

python3 ~/Documents/GitHub/Multiworm_Tracking/cmd_scripts/compressMultipleFiles.py \
/Volumes/behavgenom_archive\$/thecus /Volumes/behavgenom_archive\$/MaskedVideos \
--json_file ~/Documents/GitHub/Multiworm_Tracking/JSON_singleworm/on_food.json \
--json_file ~/Documents/GitHub/Multiworm_Tracking/single_worm_db/JSON_singleworm/on_food.json \
--is_copy_video --is_single_worm --max_num_process 24 \
--videos_list ~/Documents/GitHub/Multiworm_Tracking/single_worm_db/videos_agar_2

4 changes: 2 additions & 2 deletions single_worm_db/track_mac1.sh
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
python3 ~/Documents/GitHub/Multiworm_Tracking/cmd_scripts/trackMultipleFiles.py \
/Volumes/behavgenom_archive\$/MaskedVideos \
--json_file ~/Documents/GitHub/Multiworm_Tracking/JSON_singleworm/swimming.json \
--json_file ~/Documents/GitHub/Multiworm_Tracking/single_worm_db/JSON_singleworm/swimming.json \
--is_single_worm --max_num_process 21 --end_point INT_SKE_ORIENT \
--videos_list ~/Documents/GitHub/Multiworm_Tracking/single_worm_db/masks_swimming_1

python3 ~/Documents/GitHub/Multiworm_Tracking/cmd_scripts/trackMultipleFiles.py \
/Volumes/behavgenom_archive\$/MaskedVideos \
--json_file ~/Documents/GitHub/Multiworm_Tracking/JSON_singleworm/on_food.json \
--json_file ~/Documents/GitHub/Multiworm_Tracking/single_worm_db/JSON_singleworm/on_food.json \
--is_single_worm --max_num_process 21 --end_point INT_SKE_ORIENT \
--videos_list ~/Documents/GitHub/Multiworm_Tracking/single_worm_db/masks_agar_1

Expand Down
4 changes: 2 additions & 2 deletions single_worm_db/track_mac2.sh
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
python3 ~/Documents/GitHub/Multiworm_Tracking/cmd_scripts/trackMultipleFiles.py \
/Volumes/behavgenom_archive\$/MaskedVideos \
--json_file ~/Documents/GitHub/Multiworm_Tracking/JSON_singleworm/swimming.json \
--json_file ~/Documents/GitHub/Multiworm_Tracking/single_worm_db/JSON_singleworm/swimming.json \
--is_single_worm --max_num_process 21 --end_point INT_SKE_ORIENT \
--videos_list ~/Documents/GitHub/Multiworm_Tracking/single_worm_db/masks_swimming_2

python3 ~/Documents/GitHub/Multiworm_Tracking/cmd_scripts/trackMultipleFiles.py \
/Volumes/behavgenom_archive\$/MaskedVideos \
--json_file ~/Documents/GitHub/Multiworm_Tracking/JSON_singleworm/on_food.json \
--json_file ~/Documents/GitHub/Multiworm_Tracking/single_worm_db/JSON_singleworm/on_food.json \
--is_single_worm --max_num_process 21 --end_point INT_SKE_ORIENT \
--videos_list ~/Documents/GitHub/Multiworm_Tracking/single_worm_db/masks_agar_2

Expand Down

0 comments on commit 849120d

Please sign in to comment.