diff --git a/doc/source/coverage.csv b/doc/source/coverage.csv new file mode 100644 index 00000000..a13725da --- /dev/null +++ b/doc/source/coverage.csv @@ -0,0 +1,28 @@ +"Make movie from multiframe image ", immovie +"Play movies, videos, or image sequences ", implay +"Display image ", imshow +"Image Tool ", imtool +"Display multiple image frames as rectangular montage", montage +"Display multiple images in single figure ", subimage +"Display image as texture-mapped surface ", warp + +"Read metadata from header file of Analyze 7.5 data set ",analyze75info +"Read image data from image file of Analyze 7.5 data set ",analyze75read +"Anonymize DICOM file ",dicomanon +"Get or set active DICOM data dictionary ",dicomdict +"Read metadata from DICOM message ",dicominfo +"Find attribute in DICOM data dictionary ",dicomlookup +"Read DICOM image ",dicomread +"Generate DICOM unique identifier ",dicomuid +"Write images as DICOM files ",dicomwrite +"Read high dynamic range (HDR) image ",hdrread +"Write Radiance high dynamic range (HDR) image file ",hdrwrite +"Read metadata from Interfile file ",interfileinfo +"Read images in Interfile format ",interfileread +"Check if file is R-Set ",isrset +"Create high dynamic range image ",makehdr +"Read metadata from National Imagery Transmission Format (NITF) file",nitfinfo +"Read image from NITF file ",nitfread +"Open R-Set file ",openrset +"Create reduced resolution data set from image file ",rsetwrite +"Render high dynamic range image for viewing ",tonemap \ No newline at end of file diff --git a/doc/source/coverage_generator.py b/doc/source/coverage_generator.py new file mode 100644 index 00000000..72d79c69 --- /dev/null +++ b/doc/source/coverage_generator.py @@ -0,0 +1,57 @@ +#!/usr/bin/env python + +import csv + +def table_seperator(cols,lengths,character="-"): + output = "+" + output += '+'.join([character*(length+2) for length in lengths]) + output += "+" + return output + +def table_row(data,lengths,num_columns=None): + if num_columns is None: + num_columns = len(data) + output = "|" + for i in xrange(num_columns): + if len(data)-1 >= i: + entry = data[i] + else: + entry = "" + output += " " + entry + " "*(lengths[i] - len(entry)) + " |" + return output + +csv_path = 'test.csv' +reader = csv.reader(open(csv_path,'r'),delimiter=',',quotechar='"') + +# Find number of columns and column widths, base number of columns is +# determined by the headers +page_title = "Coverage Tables" +print page_title +print "="*len(page_title) +print +table_names = ["Image Display and Exploration","Image File I/O"] +for table in table_names: + num_columns = 3 + data = [["Functionality","Matlab","Scipy"]] + for row in reader: + if len(row) == 0: + break + data.append([entry.expandtabs() for entry in row]) + num_columns = max(num_columns,len(row)) + + column_lengths = [0]*num_columns + for row in data: + for i in xrange(len(row)): + column_lengths[i] = max(column_lengths[i],len(row[i])) + + print table + print "-"*len(table) + print + print table_seperator(num_columns,column_lengths,character="-") + print table_row(data[0],column_lengths,num_columns) + print table_seperator(num_columns,column_lengths,character="=") + for row in data[1:]: + print table_row(row,column_lengths,num_columns) + print table_seperator(num_columns,column_lengths,character='-') + print + print