Changeset 209:3658b860d020


Ignore:
Timestamp:
01/22/2011 04:35:58 PM (11 years ago)
Author:
Dmitry Fedorov <fedorov@…>
Branch:
default
Phase:
public
Message:

support for vc2010

Files:
66 added
4 edited
1 moved

Legend:

Unmodified
Added
Removed
  • LICENCE.txt

    r147 r209  
    11BioImageConvertor
    22
    3 Copyright © 2005-2010 Center for Bio-Image Informatics, UCSB
     3Copyright © 2005-2011 Center for Bio-Image Informatics, UCSB
    44<http://www.bioimage.ucsb.edu/>
    55
  • msvc2008/imgcnv.rc

    r184 r209  
    5454
    5555VS_VERSION_INFO VERSIONINFO
    56  FILEVERSION 1,50,0,50
    57  PRODUCTVERSION 1,50,0,50
     56 FILEVERSION 1,51,0,51
     57 PRODUCTVERSION 1,51,0,51
    5858 FILEFLAGSMASK 0x17L
    5959#ifdef _DEBUG
     
    7272            VALUE "CompanyName", "Center for BioImage Informatics, UCSB"
    7373            VALUE "FileDescription", "imgcnv - BioImage Converter"
    74             VALUE "FileVersion", "1, 50, 0, 50"
     74            VALUE "FileVersion", "1, 51, 0, 51"
    7575            VALUE "InternalName", "imgcnv"
    76             VALUE "LegalCopyright", "Copyright (C) 2010, Center for BioImage Informatics "
     76            VALUE "LegalCopyright", "Copyright (C) 2011, Center for BioImage Informatics "
    7777            VALUE "OriginalFilename", "imgcnv.exe"
    7878            VALUE "ProductName", "imgcnv - BioImage Converter"
    79             VALUE "ProductVersion", "1, 50, 0, 50"
     79            VALUE "ProductVersion", "1, 51, 0, 51"
    8080        END
    8181    END
  • readme.txt

    r158 r209  
    1 BioImageConvertor v1.45
     1BioImageConvertor v1.51
    22
    33Author: Dima V. Fedorov <http://www.dimin.net/>
     
    55Arguments: [[-i | -o] FILE_NAME | -t FORMAT_NAME ]
    66
    7 -c            - additional channels input file name, multiple -c are allowed, in which case multiple channels will be added, -c image must have the same size
     7Ex: imgcnv -i 1.jpg -o 2.tif -t TIFF
    88
    9 -create       - creates a new image with w-width, h-height, z-num z, t-num t, c - channels, d-bits per channel, ex: -create 100,100,1,1,3,8
     9-c                    - additional channels input file name, multiple -c are allowed, in which case multiple channels will be added, -c image must have the same size
    1010
    11 -depth        - output depth (in bits) per channel, allowed values now are: 8,16,32,64, ex: -depth 8,D,U
     11-create               - creates a new image with w-width, h-height, z-num z, t-num t, c - channels, d-bits per channel, ex: -create 100,100,1,1,3,8
     12
     13-depth                - output depth (in bits) per channel, allowed values now are: 8,16,32,64, ex: -depth 8,D,U
    1214  if followed by commma and [F|D|T|E] allowes to choose LUT method
    1315    F - Linear full range
     
    1618    E - equalized  if followed by commma and U|S|F] the type of output image can be defined    U - Unsigned integer (with depths: 8,16,32)    S - Signed integer (with depths: 8,16,32)    F - Float (with depths: 32,64,80)
    1719
    18 -display      - creates 3 channel image with preferred channel mapping
     20-display              - creates 3 channel image with preferred channel mapping
    1921
    20 -fmt          - print supported formats
     22-fmt                  - print supported formats
    2123
    22 -fmthtml      - print supported formats in HTML
     24-fmthtml              - print supported formats in HTML
    2325
    24 -fmtxml       - print supported formats in XML
     26-fmtxml               - print supported formats in XML
    2527
    26 -fuse         - Changes order and number of channels in the output additionally allowing combining channels
     28-fuse                 - Changes order and number of channels in the output additionally allowing combining channels
    2729Channels separated by comma specifying output channel order (0 means empty channel)
    2830multiple channels can be added using + sign, ex: -fuse 1+4,2+4+5,3
    2931
    30 -fuse6        - Produces 3 channel image from up to 6 channels
    31 Channels separated by comma in the following order: Red,Green,Blue,Yellow,Magenta,Cyan
     32-fuse6                - Produces 3 channel image from up to 6 channels
     33Channels separated by comma in the following order: Red,Green,Blue,Yellow,Magenta,Cyan,Gray
    3234(0 or empty value means empty channel), ex: -fuse6 1,2,3,4
    3335
    34 -geometry     - redefines geometry for any incoming image with: z-num z, t-num t, ex: -geometry 5,1
    3536
    36 -i            - input file name, multiple -i are allowed, but in multiple case each will be interpreted as a 1 page image.
     37-fuseGrey             - Produces 1 channel image averaging all input channels, uses RGB weights for 3 channel images and equal weights for all others, ex: -fuseGrey
    3738
    38 -info         - print image info
     39-geometry             - redefines geometry for any incoming image with: z-num z, t-num t, ex: -geometry 5,1
    3940
    40 -loadomexml   - reads OME-XML from a file and writes if output format is OME-TIFF
     41-i                    - input file name, multiple -i are allowed, but in multiple case each will be interpreted as a 1 page image.
    4142
    42 -meta         - print image's meta-data
     43-ihst                 - read image histogram from the file and use for nhancement operations
    4344
    44 -meta-custom  - print image's custom meta-data fields
     45-info                 - print image info
    4546
    46 -meta-parsed  - print image's parsed meta-data, excluding custom fields
     47-loadomexml           - reads OME-XML from a file and writes if output format is OME-TIFF
    4748
    48 -meta-raw     - print image's raw meta-data in one huge pile
     49-meta                 - print image's meta-data
    4950
    50 -meta-tag     - prints contents of a requested tag, ex: -tag pixel_resolution
     51-meta-custom          - print image's custom meta-data fields
    5152
    52 -multi        - creates a multi-paged image if possible (TIFF,AVI), enabled by default
     53-meta-parsed          - print image's parsed meta-data, excluding custom fields
    5354
    54 -negative     - returns negative of input image
     55-meta-raw             - print image's raw meta-data in one huge pile
    5556
    56 -norm         - normalize input into 8 bits output
     57-meta-tag             - prints contents of a requested tag, ex: -tag pixel_resolution
    5758
    58 -o            - output file name
     59-multi                - creates a multi-paged image if possible (TIFF,AVI), enabled by default
    5960
    60 -options      - specify encoder specific options, ex: -options"fps 15 bitrate 1000"
     61-negative             - returns negative of input image
     62
     63-no-overlap           - Skips frames that overlap with the previous non-overlapping frame, ex: -no-overlap 5
     64  argument defines maximum allowed overlap in , in the example it is 5
     65
     66
     67-norm                 - normalize input into 8 bits output
     68
     69-o                    - output file name
     70
     71-ohst                 - write image histogram to the file
     72
     73-options              - specify encoder specific options, ex: -options "fps 15 bitrate 1000"
    6174
    6275Encoder specific options
     
    6780JPEG encoder options:
    6881  quality N - specify encoding quality 0-100, where 100 is best, ex: quality 90
     82  progressive no - disables progressive JPEG encoding
     83  progressive yes - enables progressive JPEG encoding (default)
    6984
    7085TIFF encoder options:
     
    7287
    7388
    74 -page         - pages to extract, should be followed by page numbers separated by comma, ex: -page 1,2,5
     89-page                 - pages to extract, should be followed by page numbers separated by comma, ex: -page 1,2,5
    7590  page enumeration starts at 1 and ends at number_of_pages
    7691  page number can be a dash where dash will be substituted by a range of values, ex: -page 1,-,5  if dash is not followed by any number, maximum will be used, ex: '-page 1,-' means '-page 1,-,number_of_pages'
    7792  if dash is a first caracter, 1 will be used, ex: '-page -,5' means '-page 1,-,5'
    7893
    79 -project      - combines by MAX all inout frames into one
     94-project              - combines by MAX all inout frames into one
    8095
    81 -projectmax   - combines by MAX all inout frames into one
     96-projectmax           - combines by MAX all inout frames into one
    8297
    83 -projectmin   - combines by MIN all inout frames into one
     98-projectmin           - combines by MIN all inout frames into one
    8499
    85 -raw          - reads RAW image with w,h,c,d,p,e,t ex: -raw 100,100,3,8,10,0,uint8
     100-raw                  - reads RAW image with w,h,c,d,p,e,t ex: -raw 100,100,3,8,10,0,uint8
    86101  w-width, h-height, c - channels, d-bits per channel, p-pages
    87102  e-endianness(0-little,1-big), if in doubt choose 0
    88103  t-pixel type: int8|uint8|int16|uint16|int32|uint32|float|double, if in doubt choose uint8
    89104
    90 -rawmeta      - print image's raw meta-data in one huge pile
     105-rawmeta              - print image's raw meta-data in one huge pile
    91106
    92 -remap        - Changes order and number of channels in the output, channel numbers are separated by comma (0 means empty channel), ex: -remap 1,2,3
     107-reg-points           - Defines quality for image alignment in number of starting points, ex: -reg-points 200
     108  Suggested range is in between 32 and 512, more points slow down the processing
    93109
    94 -resample     - Is the same as resize, the difference is resample is brute force and resize uses image pyramid for speed
    95110
    96 -resize       - should be followed by: width and height of the new image, ex: -resize 640,480
     111-remap                - Changes order and number of channels in the output, channel numbers are separated by comma (0 means empty channel), ex: -remap 1,2,3
     112
     113-resample             - Is the same as resize, the difference is resample is brute force and resize uses image pyramid for speed
     114
     115-resize               - should be followed by: width and height of the new image, ex: -resize 640,480
    97116  if one of the numbers is ommited or 0, it will be computed preserving aspect ratio, ex: -resize 640,,NN
    98117  if followed by commma and [NN|BL|BC] allowes to choose interpolation method, ex: -resize 640,480,NN
     
    102121  if followed by commma AR, the size will be used as maximum bounding box to resize preserving aspect ratio, ex: 640,640,NN,AR
    103122
    104 -resize3d     - performs 3D interpolation on an input image, ex: -resize3d 640,480,16
     123-resize3d             - performs 3D interpolation on an input image, ex: -resize3d 640,480,16
    105124  if one of the W/H numbers is ommited or 0, it will be computed preserving aspect ratio, ex: -resize3d 640,,16,NN
    106125  if followed by commma and [NN|BL|BC] allowes to choose interpolation method, ex: -resize3d 640,480,16,BC
     
    110129  if followed by commma AR, the size will be used as maximum bounding box to resize preserving aspect ratio, ex: 640,640,16,BC,AR
    111130
    112 -roi          - region of interest, should be followed by: x1,y1,x2,y2 that defines ROI rectangle, ex: -roi 10,10,100,100
     131-resolution           - redefines resolution for any incoming image with: x,y,z,t where x,y,z are in microns and t in seconds  ex: -resolution 0.012,0.012,1,0
     132
     133-roi                  - region of interest, should be followed by: x1,y1,x2,y2 that defines ROI rectangle, ex: -roi 10,10,100,100
    113134  if x1 or y1 are ommited they will be set to 0, ex: -roi ,,100,100 means 0,0,100,100
    114135  if x2 or y2 are ommited they will be set to image size, ex: -roi 10,10,, means 10,10,width-1,height-1
    115136
    116 -rotate       - rotates the image by deg degrees, only accepted valueas now are: 90, -90 and 180
     137-rotate               - rotates the image by deg degrees, only accepted valueas now are: 90, -90 and 180
    117138
    118 -sampleframes - samples for reading every Nth frame (useful for videos), ex: -sampleframes 5
     139-sampleframes         - samples for reading every Nth frame (useful for videos), ex: -sampleframes 5
    119140
    120 -single       - disables multi-page creation mode
     141-single               - disables multi-page creation mode
    121142
    122 -stretch      - stretch data to it's full range
     143-skip-frames-leading  - skip N initial frames of a sequence, ex: -skip-frames-leading 5
    123144
    124 -supported    - prints yes/no if the file can be decoded
     145-skip-frames-trailing - skip N final frames of a sequence, ex: -skip-frames-trailing 5
    125146
    126 -t            - output format
     147-stretch              - stretch data to it's full range
    127148
    128 -tile         - tilte the image and store tiles in output directory, ex: -tile 256
     149-supported            - prints yes/no if the file can be decoded
    129150
    130 -v            - prints version
     151-t                    - output format
     152
     153-tile                 - tilte the image and store tiles in the output directory, ex: -tile 256
     154  argument defines the size of the tiles in pixels
     155  tiles will be created based on the outrput file name with inserted L, X, Y, where    L - is a resolution level, L=0 is native resolution, L=1 is 2x smaller, and so on    X and Y - are tile indices in X and Y, where the first tile is 0,0, second in X is: 1,0 and so on  ex: '-o my_file.jpg' will produce files: 'my_file_LLL_XXX_YYY.jpg'
     156
     157
     158-v                    - prints version
     159
     160-verbose              - output information about the processing progress, ex: -verbose
     161  verbose allows argument that defines the amount of info, currently: 1 and 2
     162  where: 1 is the light info output, 2 is full output
     163
     164
    131165
    132166---------------------------------------------------------------------------
  • testing/runtest.py

    r192 r209  
    1313__module__    = "imgcnv_testing"
    1414__author__    = "Dmitry Fedorov"
    15 __version__   = "1.5"
     15__version__   = "1.6"
    1616__revision__  = "$Rev$"
    1717__date__      = "$Date$"
     
    2222from copy import deepcopy
    2323from subprocess import Popen, call, PIPE
     24import time
    2425
    2526IMGCNV='./imgcnv'
     
    389390if len(mode) <= 1: mode.append('all')
    390391
     392start = time.time()
    391393
    392394if 'all' in mode or 'reading' in mode:
     
    795797
    796798
     799end = time.time()
     800elapsed= end - start
     801
    797802# print summary
    798 print '\n\nTest summary:\n'
     803print '\n\nFollowing tests took %s seconds:\n'%(elapsed)
    799804
    800805if passed>0 and failed==0:
Note: See TracChangeset for help on using the changeset viewer.