metamri 0.1.23 → 0.2.0
Sign up to get free protection for your applications and to get access to all the features.
- data/Rakefile +21 -17
- data/VERSION +1 -1
- data/bin/list_visit +18 -9
- data/lib/metamri/core_additions.rb +32 -10
- data/lib/metamri/image_dataset_quality_check_resource.rb +26 -0
- data/lib/metamri/raw_image_dataset.rb +76 -32
- data/lib/metamri/raw_image_dataset_resource.rb +5 -1
- data/lib/metamri/raw_image_dataset_thumbnail.rb +25 -6
- data/lib/metamri/raw_image_file.rb +242 -119
- data/lib/metamri/visit_raw_data_directory.rb +29 -22
- data/metamri.gemspec +51 -45
- data/{test → spec}/helper_spec.rb +0 -2
- data/{test → spec/unit}/nifti_builder_spec.rb +0 -0
- data/spec/unit/raw_image_dataset_spec.rb +35 -0
- data/{test → spec/unit}/raw_image_dataset_thumbnail_spec.rb +18 -12
- data/spec/unit/raw_image_file_spec.rb +45 -0
- data/test/fixtures/s03_bravo.0156.yml +937 -0
- data/test/raw_image_file_test.rb +13 -12
- data/test/test_helper.rb +2 -0
- metadata +22 -15
- data/.gitignore +0 -7
data/test/raw_image_file_test.rb
CHANGED
@@ -1,23 +1,24 @@
|
|
1
1
|
# To change this template, choose Tools | Templates
|
2
2
|
# and open the template in the editor.
|
3
3
|
|
4
|
-
|
4
|
+
require 'test_helper'
|
5
5
|
|
6
6
|
require 'test/unit'
|
7
7
|
require 'metamri/raw_image_file'
|
8
8
|
|
9
9
|
class RawImageFileTest < Test::Unit::TestCase
|
10
10
|
def setup
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
@
|
11
|
+
@GE_IFile = File.join($MRI_DATA), 'test_fixtures/I.001'
|
12
|
+
@Dicom = File.join($MRI_DATA), 'test_fixtures/S4_EFGRE3D.0001'
|
13
|
+
@EarlyGEPfile = File.join($MRI_DATA), 'test_fixtures/P59392.7'
|
14
|
+
@LateGEPfile = File.join($MRI_DATA), 'test_fixtures/P27648.7'
|
15
|
+
@GEX750Dicom = File.join($MRI_DATA), 'test_fixtures/s03_bravo.0156'
|
16
|
+
@notafile = File.join($MRI_DATA), 'test_fixtures/XXX.XXX'
|
17
|
+
@ged = RawImageFile.new(@GE_IFile)
|
18
|
+
@did = RawImageFile.new(@Dicom)
|
19
|
+
@egep = RawImageFile.new(@EarlyGEPfile)
|
20
|
+
@lgep = RawImageFile.new(@LateGEPfile)
|
21
|
+
|
21
22
|
end
|
22
23
|
|
23
24
|
def test_gehdr_dicom_init
|
@@ -32,7 +33,7 @@ class RawImageFileTest < Test::Unit::TestCase
|
|
32
33
|
end
|
33
34
|
def test_rubydicom_dicom_init
|
34
35
|
assert_nothing_raised do
|
35
|
-
RawImageFile.new(@
|
36
|
+
RawImageFile.new(@GEX750Dicom)
|
36
37
|
end
|
37
38
|
end
|
38
39
|
def test_early_gehdr_pfile_init
|
data/test/test_helper.rb
ADDED
metadata
CHANGED
@@ -4,9 +4,9 @@ version: !ruby/object:Gem::Version
|
|
4
4
|
prerelease: false
|
5
5
|
segments:
|
6
6
|
- 0
|
7
|
-
-
|
8
|
-
-
|
9
|
-
version: 0.
|
7
|
+
- 2
|
8
|
+
- 0
|
9
|
+
version: 0.2.0
|
10
10
|
platform: ruby
|
11
11
|
authors:
|
12
12
|
- Kristopher J. Kosmatka
|
@@ -14,7 +14,7 @@ autorequire:
|
|
14
14
|
bindir: bin
|
15
15
|
cert_chain: []
|
16
16
|
|
17
|
-
date: 2010-11-
|
17
|
+
date: 2010-11-19 00:00:00 -06:00
|
18
18
|
default_executable:
|
19
19
|
dependencies:
|
20
20
|
- !ruby/object:Gem::Dependency
|
@@ -56,17 +56,16 @@ dependencies:
|
|
56
56
|
description: Extraction of MRI metadata and insertion into compatible sqlite3 databases.
|
57
57
|
email: kk4@medicine.wisc.edu
|
58
58
|
executables:
|
59
|
-
-
|
59
|
+
- convert_visit.rb
|
60
60
|
- import_visit.rb
|
61
61
|
- import_respiratory_files.rb
|
62
|
+
- import_study.rb
|
62
63
|
- list_visit
|
63
|
-
- convert_visit.rb
|
64
64
|
extensions: []
|
65
65
|
|
66
66
|
extra_rdoc_files:
|
67
67
|
- README.rdoc
|
68
68
|
files:
|
69
|
-
- .gitignore
|
70
69
|
- Manifest
|
71
70
|
- README.rdoc
|
72
71
|
- Rakefile
|
@@ -78,6 +77,7 @@ files:
|
|
78
77
|
- bin/list_visit
|
79
78
|
- lib/metamri.rb
|
80
79
|
- lib/metamri/core_additions.rb
|
80
|
+
- lib/metamri/image_dataset_quality_check_resource.rb
|
81
81
|
- lib/metamri/mysql_tools.rb
|
82
82
|
- lib/metamri/nifti_builder.rb
|
83
83
|
- lib/metamri/raw_image_dataset.rb
|
@@ -88,15 +88,19 @@ files:
|
|
88
88
|
- lib/metamri/visit_raw_data_directory.rb
|
89
89
|
- lib/metamri/visit_raw_data_directory_resource.rb
|
90
90
|
- metamri.gemspec
|
91
|
+
- spec/helper_spec.rb
|
92
|
+
- spec/unit/nifti_builder_spec.rb
|
93
|
+
- spec/unit/raw_image_dataset_spec.rb
|
94
|
+
- spec/unit/raw_image_dataset_thumbnail_spec.rb
|
95
|
+
- spec/unit/raw_image_file_spec.rb
|
91
96
|
- test/fixtures/respiratory_fixtures.yaml
|
92
97
|
- test/fixtures/s03_bravo.0156
|
98
|
+
- test/fixtures/s03_bravo.0156.yml
|
93
99
|
- test/fixtures/thumbnail.png
|
94
100
|
- test/fixtures/thumbnail_slicer.png
|
95
|
-
- test/helper_spec.rb
|
96
|
-
- test/nifti_builder_spec.rb
|
97
101
|
- test/raw_image_dataset_test.rb
|
98
|
-
- test/raw_image_dataset_thumbnail_spec.rb
|
99
102
|
- test/raw_image_file_test.rb
|
103
|
+
- test/test_helper.rb
|
100
104
|
- test/visit_duplication_test.rb
|
101
105
|
- test/visit_test.rb
|
102
106
|
has_rdoc: true
|
@@ -104,8 +108,8 @@ homepage: http://github.com/brainmap/metamri
|
|
104
108
|
licenses: []
|
105
109
|
|
106
110
|
post_install_message:
|
107
|
-
rdoc_options:
|
108
|
-
|
111
|
+
rdoc_options: []
|
112
|
+
|
109
113
|
require_paths:
|
110
114
|
- lib
|
111
115
|
required_ruby_version: !ruby/object:Gem::Requirement
|
@@ -130,10 +134,13 @@ signing_key:
|
|
130
134
|
specification_version: 3
|
131
135
|
summary: MRI metadata
|
132
136
|
test_files:
|
133
|
-
-
|
137
|
+
- spec/helper_spec.rb
|
138
|
+
- spec/unit/nifti_builder_spec.rb
|
139
|
+
- spec/unit/raw_image_dataset_spec.rb
|
140
|
+
- spec/unit/raw_image_dataset_thumbnail_spec.rb
|
141
|
+
- spec/unit/raw_image_file_spec.rb
|
134
142
|
- test/raw_image_dataset_test.rb
|
135
143
|
- test/raw_image_file_test.rb
|
144
|
+
- test/test_helper.rb
|
136
145
|
- test/visit_duplication_test.rb
|
137
146
|
- test/visit_test.rb
|
138
|
-
- test/raw_image_dataset_thumbnail_spec.rb
|
139
|
-
- test/helper_spec.rb
|