Changeset 6182


Ignore:
Timestamp:
04/23/10 11:38:01 (10 years ago)
Author:
curtis
Message:

Fix up logging with Bio-Formats command line tools.
This removes the hard dependency on log4j in Bio-Formats, so it should be
possible to log with other logging frameworks via SLF4J now. There is also
a log4j configuration filein the tools folder now, which should make it easier
to configure output for debugging, stack traces, etc.

Location:
trunk
Files:
30 edited
1 moved

Legend:

Unmodified
Added
Removed
  • trunk/components/bio-formats/build.properties

    r6048 r6182  
    1717                           ${artifact.dir}/poi-loci.jar:\ 
    1818                           ${lib.dir}/forms-1.3.0.jar:\ 
    19                            ${lib.dir}/log4j-1.2.15.jar:\ 
    2019                           ${lib.dir}/netcdf-4.0.jar:\ 
    2120                           ${lib.dir}/slf4j-api-1.5.10.jar:\ 
     
    3231component.runtime-cp     = ${component.classpath}:\ 
    3332                           ${artifact.dir}/ome-io.jar:\ 
    34                            ${artifact.dir}/ome-notes.jar 
     33                           ${artifact.dir}/ome-notes.jar:\ 
     34                           ${lib.dir}/log4j-1.2.15.jar:\ 
     35                           ${lib.dir}/slf4j-log4j12-1.5.10.jar 
    3536 
    3637# Used by TestNG suite that tests the absence of classes from ome-xml.jar 
  • trunk/components/bio-formats/src/loci/formats/FormatHandler.java

    r6141 r6182  
    2626import org.slf4j.Logger; 
    2727import org.slf4j.LoggerFactory; 
     28 
     29// HACK: for scan-deps.pl: The following packages are not actually "optional": 
     30// optional org.apache.log4j, optional org.slf4j.impl 
    2831 
    2932/** 
  • trunk/components/bio-formats/src/loci/formats/tools/ImageConverter.java

    r6128 r6182  
    4848import loci.formats.services.OMEXMLService; 
    4949 
    50 import org.apache.log4j.ConsoleAppender; 
    51 import org.apache.log4j.Level; 
    52 import org.apache.log4j.PatternLayout; 
    5350import org.slf4j.Logger; 
    5451import org.slf4j.LoggerFactory; 
     
    7875    throws FormatException, IOException 
    7976  { 
    80     org.apache.log4j.Logger root = org.apache.log4j.Logger.getRootLogger(); 
    81     root.setLevel(Level.INFO); 
    82     ConsoleAppender appender = new ConsoleAppender(new PatternLayout("%m%n")); 
    83     root.addAppender(appender); 
    84  
    8577    String in = null, out = null; 
    8678    String map = null; 
     
    9385        if (args[i].startsWith("-") && args.length > 1) { 
    9486          if (args[i].equals("-debug")) { 
    95             root.setLevel(Level.DEBUG); 
     87            LOGGER.warn("To enable debugging, edit the log4j.properties file,"); 
     88            LOGGER.warn("changing log4j.rootCategory from INFO to DEBUG"); 
     89            LOGGER.warn("(or TRACE for extreme verbosity)."); 
    9690          } 
    9791          else if (args[i].equals("-stitch")) stitch = true; 
     
    210204 
    211205    String format = writer.getFormat(); 
    212     LOGGER.info("[{}] -> {} [{}] ", 
     206    LOGGER.info("[{}] -> {} [{}]", 
    213207      new Object[] {reader.getFormat(), out, format}); 
    214208    long mid = System.currentTimeMillis(); 
     
    228222    } 
    229223 
    230     appender.setLayout(new PatternLayout("%m")); 
    231  
    232224    int total = 0; 
    233225    int num = writer.canDoStacks() ? reader.getSeriesCount() : 1; 
     
    235227    int first = series == -1 ? 0 : series; 
    236228    int last = series == -1 ? num : series + 1; 
     229    long timeLastLogged = System.currentTimeMillis(); 
    237230    for (int q=first; q<last; q++) { 
    238231      reader.setSeries(q); 
     
    256249        writer.saveBytes(buf, q, lastInSeries, q == last - 1 && lastInSeries); 
    257250        long e = System.currentTimeMillis(); 
    258         LOGGER.info("."); 
    259251        read += m - s; 
    260252        write += e - m; 
     253 
     254        // log number of planes processed every second or so 
     255        if (i == numImages - 1 || (e - timeLastLogged) / 1000 > 0) { 
     256          int current = i + 1; 
     257          int percent = 100 * current / numImages; 
     258          StringBuilder sb = new StringBuilder(); 
     259          sb.append("\t"); 
     260          int numSeries = last - first; 
     261          if (numSeries > 1) { 
     262            sb.append("Series "); 
     263            sb.append(q); 
     264            sb.append(": converted "); 
     265          } 
     266          else sb.append("Converted "); 
     267          LOGGER.info(sb.toString() + "{}/{} planes ({}%)", 
     268            new Object[] {current, numImages, percent}); 
     269          timeLastLogged = e; 
     270        } 
    261271      } 
    262272    } 
    263273    writer.close(); 
    264274    long end = System.currentTimeMillis(); 
    265     appender.setLayout(new PatternLayout("%m%n")); 
    266     LOGGER.info(" [done]"); 
     275    LOGGER.info("[done]"); 
    267276 
    268277    // output timing results 
  • trunk/components/bio-formats/src/loci/formats/tools/ImageInfo.java

    r6141 r6182  
    6262import loci.formats.services.OMEXMLService; 
    6363 
    64 import org.apache.log4j.ConsoleAppender; 
    65 import org.apache.log4j.Level; 
    66 import org.apache.log4j.PatternLayout; 
    6764import org.slf4j.Logger; 
    6865import org.slf4j.LoggerFactory; 
     
    8178 
    8279  private static final Logger LOGGER = LoggerFactory.getLogger(ImageInfo.class); 
     80  private static final String NEWLINE = System.getProperty("line.separator"); 
    8381 
    8482  // -- Fields -- 
     
    122120  private boolean preIsMinMaxPop = false; 
    123121 
    124   private ConsoleAppender appender; 
    125   private PatternLayout originalLayout; 
    126   private PatternLayout altLayout = new PatternLayout("%m"); 
    127  
    128122  // -- ImageInfo methods -- 
    129123 
    130124  public void parseArgs(String[] args) { 
    131     org.apache.log4j.Logger root = org.apache.log4j.Logger.getRootLogger(); 
    132     root.setLevel(Level.INFO); 
    133     originalLayout = new PatternLayout("%m%n"); 
    134     appender = new ConsoleAppender(originalLayout); 
    135     root.addAppender(appender); 
    136  
    137125    id = null; 
    138126    printVersion = false; 
     
    182170        else if (args[i].equals("-autoscale")) autoscale = true; 
    183171        else if (args[i].equals("-debug")) { 
    184           root.setLevel(Level.DEBUG); 
     172          LOGGER.warn("To enable debugging, edit the log4j.properties file,"); 
     173          LOGGER.warn("changing log4j.rootCategory from INFO to DEBUG"); 
     174          LOGGER.warn("(or TRACE for extreme verbosity)."); 
    185175        } 
    186176        else if (args[i].equals("-preload")) preload = true; 
     
    192182          width = Integer.parseInt(st.nextToken()); 
    193183          height = Integer.parseInt(st.nextToken()); 
    194         } 
    195         else if (args[i].equals("-level")) { 
    196           root.setLevel(Level.TRACE); 
    197184        } 
    198185        else if (args[i].equals("-range")) { 
     
    398385 
    399386    // read basic metadata 
    400     LOGGER.info("\nReading core metadata"); 
     387    LOGGER.info(""); 
     388    LOGGER.info("Reading core metadata"); 
    401389    LOGGER.info("{} = {}", stitch ? "File pattern" : "Filename", 
    402390      stitch ? id : reader.getCurrentFile()); 
     
    431419    LOGGER.info("Series count = {}", seriesCount); 
    432420    MetadataStore ms = reader.getMetadataStore(); 
    433     MetadataRetrieve mr = ms instanceof MetadataRetrieve? (MetadataRetrieve) ms 
    434         : null; 
     421    MetadataRetrieve mr = ms instanceof MetadataRetrieve ? 
     422      (MetadataRetrieve) ms : null; 
    435423    for (int j=0; j<seriesCount; j++) { 
    436424      reader.setSeries(j); 
     
    476464      LOGGER.info("\tInterleaved = {}", interleaved); 
    477465 
    478       appender.setLayout(altLayout); 
    479  
    480       LOGGER.info("\tIndexed = {} ({} color", indexed, !falseColor); 
     466      StringBuilder sb = new StringBuilder(); 
     467      sb.append("\tIndexed = "); 
     468      sb.append(indexed); 
     469      sb.append("("); 
     470      sb.append(!falseColor); 
     471      sb.append("color"); 
    481472      if (table8 != null) { 
    482         LOGGER.info(", 8-bit LUT: {} x ", table8.length); 
    483         LOGGER.info(table8[0] == null ? "null" : "" + table8[0].length); 
     473        sb.append(", 8-bit LUT: "); 
     474        sb.append(table8.length); 
     475        sb.append("x "); 
     476        sb.append(table8[0] == null ? "null" : "" + table8[0].length); 
    484477      } 
    485478      if (table16 != null) { 
    486         LOGGER.info(", 16-bit LUT: {} x ", table16.length); 
    487         LOGGER.info(table16[0] == null ? "null" : "" + table16[0].length); 
    488       } 
    489  
    490       appender.setLayout(originalLayout); 
    491       LOGGER.info(")"); 
     479        sb.append(", 16-bit LUT: "); 
     480        sb.append(table16.length); 
     481        sb.append("x "); 
     482        sb.append(table16[0] == null ? "null" : "" + table16[0].length); 
     483      } 
     484      sb.append(")"); 
     485      LOGGER.info(sb.toString()); 
     486 
    492487      if (table8 != null && table16 != null) { 
    493488        LOGGER.warn("\t************ multiple LUTs ************"); 
     
    498493      LOGGER.info("\tSizeT = {}", sizeT); 
    499494 
    500       appender.setLayout(altLayout); 
    501       LOGGER.info("\tSizeC = {}", sizeC); 
     495      sb.setLength(0); 
     496      sb.append("\tSizeC = "); 
     497      sb.append(sizeC); 
    502498      if (sizeC != effSizeC) { 
    503         LOGGER.info(" (effectively {})", effSizeC); 
     499        sb.append(" (effectively "); 
     500        sb.append(effSizeC); 
     501        sb.append(")"); 
    504502      } 
    505503      int cProduct = 1; 
     
    508506      } 
    509507      else { 
    510         LOGGER.info(" ("); 
     508        sb.append(" ("); 
    511509        for (int i=0; i<cLengths.length; i++) { 
    512           if (i > 0) LOGGER.info(" x "); 
    513           LOGGER.info("{} {}", cLengths[i], cTypes[i]); 
     510          if (i > 0) sb.append(" x "); 
     511          sb.append(cLengths[i]); 
     512          sb.append(" "); 
     513          sb.append(cTypes[i]); 
    514514          cProduct *= cLengths[i]; 
    515515        } 
    516         LOGGER.info(")"); 
    517       } 
    518       appender.setLayout(originalLayout); 
    519       LOGGER.info(""); 
     516        sb.append(")"); 
     517      } 
     518      LOGGER.info(sb.toString()); 
     519 
    520520      if (cLengths.length == 0 || cProduct != sizeC) { 
    521521        LOGGER.warn("\t************ C dimension mismatch ************"); 
     
    550550        int[][] zct = new int[indices.length][]; 
    551551        int[] indices2 = new int[indices.length]; 
    552         appender.setLayout(altLayout); 
     552 
     553        sb.setLength(0); 
    553554        for (int i=0; i<indices.length; i++) { 
    554555          zct[i] = reader.getZCTCoords(indices[i]); 
    555556          indices2[i] = reader.getIndex(zct[i][0], zct[i][1], zct[i][2]); 
    556           LOGGER.info("\tPlane #{} <=> Z {}, C {}, T {}", 
    557             new Object[] {indices[i], zct[i][0], zct[i][1], zct[i][2]}); 
     557          sb.append("\tPlane #"); 
     558          sb.append(indices[i]); 
     559          sb.append(" <=> Z "); 
     560          sb.append(zct[i][0]); 
     561          sb.append(", C "); 
     562          sb.append(zct[i][1]); 
     563          sb.append(", T "); 
     564          sb.append(zct[i][2]); 
    558565          if (indices[i] != indices2[i]) { 
    559             LOGGER.info(" [mismatch: {}]\r\n", indices2[i]); 
     566            sb.append(" [mismatch: "); 
     567            sb.append(indices2[i]); 
     568            sb.append("]"); 
     569            sb.append(NEWLINE); 
    560570          } 
    561           else LOGGER.info("\r\n"); 
    562         } 
    563         appender.setLayout(originalLayout); 
     571          else sb.append(NEWLINE); 
     572        } 
     573        LOGGER.info(sb.toString()); 
    564574      } 
    565575    } 
     
    608618 
    609619    // output min/max results 
    610     LOGGER.info("\nMin/max values:"); 
     620    LOGGER.info(""); 
     621    LOGGER.info("Min/max values:"); 
    611622    for (int c=0; c<sizeC; c++) { 
    612623      LOGGER.info("\tChannel {}:", c); 
     
    620631        knownMax[c], preKnownMax[c]); 
    621632    } 
    622     appender.setLayout(altLayout); 
    623     LOGGER.info("\tFirst plane minimum(s) ="); 
    624     if (planeMin == null) LOGGER.info(" none"); 
     633    StringBuilder sb = new StringBuilder(); 
     634    sb.append("\tFirst plane minimum(s) ="); 
     635    if (planeMin == null) sb.append(" none"); 
    625636    else { 
    626637      for (int subC=0; subC<planeMin.length; subC++) { 
    627         LOGGER.info(" {}", planeMin[subC]); 
    628       } 
    629     } 
    630     LOGGER.info(" (initially"); 
    631     if (prePlaneMin == null) LOGGER.info(" none"); 
     638        sb.append(" "); 
     639        sb.append(planeMin[subC]); 
     640      } 
     641    } 
     642    sb.append(" (initially"); 
     643    if (prePlaneMin == null) sb.append(" none"); 
    632644    else { 
    633645      for (int subC=0; subC<prePlaneMin.length; subC++) { 
    634         LOGGER.info(" {}", prePlaneMin[subC]); 
    635       } 
    636     } 
    637     appender.setLayout(originalLayout); 
    638     LOGGER.info(")"); 
    639     appender.setLayout(altLayout); 
    640     LOGGER.info("\tFirst plane maximum(s) ="); 
    641     if (planeMax == null) LOGGER.info(" none"); 
     646        sb.append(" "); 
     647        sb.append(prePlaneMin[subC]); 
     648      } 
     649    } 
     650    sb.append(")"); 
     651    LOGGER.info(sb.toString()); 
     652 
     653    sb.setLength(0); 
     654    sb.append("\tFirst plane maximum(s) ="); 
     655    if (planeMax == null) sb.append(" none"); 
    642656    else { 
    643657      for (int subC=0; subC<planeMax.length; subC++) { 
    644         LOGGER.info(" {}", planeMax[subC]); 
    645       } 
    646     } 
    647     LOGGER.info(" (initially"); 
    648     if (prePlaneMax == null) LOGGER.info(" none"); 
     658        sb.append(" "); 
     659        sb.append(planeMax[subC]); 
     660      } 
     661    } 
     662    sb.append(" (initially"); 
     663    if (prePlaneMax == null) sb.append(" none"); 
    649664    else { 
    650665      for (int subC=0; subC<prePlaneMax.length; subC++) { 
    651         LOGGER.info(" {}", prePlaneMax[subC]); 
    652       } 
    653     } 
    654     appender.setLayout(originalLayout); 
    655     LOGGER.info(")"); 
     666        sb.append(" "); 
     667        sb.append(prePlaneMax[subC]); 
     668      } 
     669    } 
     670    sb.append(")"); 
     671    LOGGER.info(sb.toString()); 
     672 
    656673    LOGGER.info("\tMin/max populated = {} (initially {})", 
    657674      isMinMaxPop, preIsMinMaxPop); 
     
    662679      (" series #" + series) : ""; 
    663680    LOGGER.info(""); 
    664     appender.setLayout(altLayout); 
    665     LOGGER.info("Reading {} pixel data ", seriesLabel); 
     681 
    666682    int num = reader.getImageCount(); 
    667683    if (start < 0) start = 0; 
     
    671687    if (end < start) end = start; 
    672688 
     689    LOGGER.info("Reading{} pixel data ({}-{})", 
     690      new Object[] {seriesLabel, start, end}); 
     691 
    673692    int sizeX = reader.getSizeX(); 
    674693    int sizeY = reader.getSizeY(); 
     
    678697    int pixelType = reader.getPixelType(); 
    679698 
    680     LOGGER.info("({}-{}) ", start, end); 
    681699    BufferedImage[] images = new BufferedImage[end - start + 1]; 
    682     long s2 = System.currentTimeMillis(); 
    683     boolean mismatch = false; 
     700    long s = System.currentTimeMillis(); 
     701    long timeLastLogged = s; 
    684702    for (int i=start; i<=end; i++) { 
    685703      if (!fastBlit) { 
     
    733751        reader.get16BitLookupTable() == null) 
    734752      { 
    735         LOGGER.info("\r\n"); 
    736         LOGGER.warn("************ no LUT for plane #{} ************", i); 
     753        LOGGER.info(NEWLINE); 
     754        LOGGER.warn("\t************ no LUT for plane #{} ************", i); 
    737755      } 
    738756 
     
    740758      int pixType = AWTImageTools.getPixelType(images[i - start]); 
    741759      if (pixType != pixelType && pixType != pixelType + 1 && !fastBlit) { 
    742         if (!mismatch) { 
    743           LOGGER.info("\r\n"); 
    744           mismatch = true; 
    745         } 
    746760        LOGGER.info("\tPlane #{}: pixel type mismatch: {}/{}", 
    747761          new Object[] {i, FormatTools.getPixelTypeString(pixType), 
     
    749763      } 
    750764      else { 
    751         mismatch = false; 
    752         LOGGER.info("."); 
    753       } 
    754     } 
    755     long e2 = System.currentTimeMillis(); 
    756     if (!mismatch) LOGGER.info(" "); 
    757     appender.setLayout(originalLayout); 
     765        // log number of planes read every second or so 
     766        long t = System.currentTimeMillis(); 
     767        if (i == end || (t - timeLastLogged) / 1000 > 0) { 
     768          int current = i - start + 1; 
     769          int total = end - start + 1; 
     770          int percent = 100 * current / total; 
     771          LOGGER.info("\tRead {}/{} planes ({}%)", new Object[] { 
     772            current, total, percent 
     773          }); 
     774          timeLastLogged = t; 
     775        } 
     776      } 
     777    } 
     778    long e = System.currentTimeMillis(); 
     779 
    758780    LOGGER.info("[done]"); 
    759781 
    760782    // output timing results 
    761     float sec2 = (e2 - s2) / 1000f; 
    762     float avg = (float) (e2 - s2) / images.length; 
    763     LOGGER.info("{}s elapsed ({}ms per plane)", sec2, avg); 
     783    float sec = (e - s) / 1000f; 
     784    float avg = (float) (e - s) / images.length; 
     785    LOGGER.info("{}s elapsed ({}ms per plane)", sec, avg); 
    764786 
    765787    if (minmax) printMinMaxValues(); 
     
    853875 
    854876    // initialize reader 
    855     long s1 = System.currentTimeMillis(); 
     877    long s = System.currentTimeMillis(); 
    856878    reader.setId(id); 
    857     long e1 = System.currentTimeMillis(); 
    858     float sec1 = (e1 - s1) / 1000f; 
    859     LOGGER.info("Initialization took {}s", sec1); 
     879    long e = System.currentTimeMillis(); 
     880    float sec = (e - s) / 1000f; 
     881    LOGGER.info("Initialization took {}s", sec); 
    860882 
    861883    configureReaderPostInit(); 
  • trunk/components/bio-formats/src/loci/formats/tools/PrintFormatTable.java

    r6128 r6182  
    3333import loci.formats.ImageWriter; 
    3434 
    35 import org.apache.log4j.ConsoleAppender; 
    36 import org.apache.log4j.Level; 
    37 import org.apache.log4j.PatternLayout; 
    3835import org.slf4j.Logger; 
    3936import org.slf4j.LoggerFactory; 
     
    162159 
    163160  public static void printSupportedFormats(String[] args) { 
    164     org.apache.log4j.Logger root = org.apache.log4j.Logger.getRootLogger(); 
    165     root.setLevel(Level.INFO); 
    166     root.addAppender(new ConsoleAppender(new PatternLayout("%m%n"))); 
    167  
    168161    PrintStyles printStyle = PrintStyles.TXT; 
    169162 
  • trunk/scan-deps.pl

    r6165 r6182  
    604604my %slf4j_impl = ( 
    605605  NAME    => "slf4j-log4j", 
    606   TITLE   => "Simple Logging Facade for Java Binding", 
     606  TITLE   => "Simple Logging Facade for Java log4j Binding", 
    607607  JAR     => "slf4j-log4j12-1.5.10.jar", 
    608608  PACKAGE => "org.slf4j.impl", 
  • trunk/tools/bfconvert

    r5987 r6182  
    2020elif [ -e "$DIR/loci_tools.jar" ] || [ -e "$DIR/bio-formats.jar" ] 
    2121then 
    22   java -mx512m -cp "$DIR/bio-formats.jar":"$DIR/loci_tools.jar" $PROG "$@" 
     22  java -mx512m \ 
     23    -cp "$DIR":"$DIR/bio-formats.jar":"$DIR/loci_tools.jar" $PROG "$@" 
    2324else 
    2425  echo "Required JAR libraries not found. Please download:" 
  • trunk/tools/bfconvert.bat

    r5987 r6182  
    2828:found 
    2929rem Library found; try to launch 
    30 java -mx512m -cp "%DIR%bio-formats.jar";"%DIR%loci_tools.jar" %PROG% %* 
     30java -mx512m -cp "%DIR%";"%DIR%bio-formats.jar";"%DIR%loci_tools.jar" %PROG% %* 
    3131goto end 
    3232 
  • trunk/tools/bfview

    r5987 r6182  
    2020elif [ -e "$DIR/loci_tools.jar" ] || [ -e "$DIR/bio-formats.jar" ] 
    2121then 
    22   java -mx512m -cp "$DIR/bio-formats.jar":"$DIR/loci_tools.jar" $PROG "$@" 
     22  java -mx512m -cp "$DIR":"$DIR/bio-formats.jar":"$DIR/loci_tools.jar" $PROG "$@" 
    2323else 
    2424  echo "Required JAR libraries not found. Please download:" 
  • trunk/tools/bfview.bat

    r5987 r6182  
    2828:found 
    2929rem Library found; try to launch 
    30 java -mx512m -cp "%DIR%bio-formats.jar";"%DIR%loci_tools.jar" %PROG% %* 
     30java -mx512m -cp "%DIR%";"%DIR%bio-formats.jar";"%DIR%loci_tools.jar" %PROG% %* 
    3131goto end 
    3232 
  • trunk/tools/domainlist

    r5987 r6182  
    2020elif [ -e "$DIR/loci_tools.jar" ] || [ -e "$DIR/bio-formats.jar" ] 
    2121then 
    22   java -cp "$DIR/bio-formats.jar":"$DIR/loci_tools.jar" $PROG "$@" 
     22  java -cp "$DIR":"$DIR/bio-formats.jar":"$DIR/loci_tools.jar" $PROG "$@" 
    2323else 
    2424  echo "Required JAR libraries not found. Please download:" 
  • trunk/tools/domainlist.bat

    r5987 r6182  
    2828:found 
    2929rem Library found; try to launch 
    30 java -cp "%DIR%bio-formats.jar";"%DIR%loci_tools.jar" %PROG% %* 
     30java -cp "%DIR%";"%DIR%bio-formats.jar";"%DIR%loci_tools.jar" %PROG% %* 
    3131goto end 
    3232 
  • trunk/tools/editor

    r5987 r6182  
    2525  [ -e "$DIR/ome-java-deprecated.jar" ] 
    2626then 
    27   java -mx512m -cp "$DIR/bio-formats.jar":"$DIR/loci_tools.jar":"$DIR/ome-editor.jar":"$DIR/ome-java.jar":"$DIR/ome-java-deprecated.jar" $PROG "$@" 
     27  java -mx512m -cp "$DIR":"$DIR/bio-formats.jar":"$DIR/loci_tools.jar":"$DIR/ome-editor.jar":"$DIR/ome-java.jar":"$DIR/ome-java-deprecated.jar" $PROG "$@" 
    2828else 
    2929  echo "Required JAR libraries not found. Please download:" 
  • trunk/tools/editor.bat

    r5987 r6182  
    3232:found 
    3333rem Library found; try to launch 
    34 java -mx512m -cp "%DIR%bio-formats.jar";"%DIR%loci_tools.jar";"%DIR%ome-editor.jar";"%DIR%ome-java.jar";"%DIR%ome-java-deprecated.jar" %PROG% %* 
     34java -mx512m -cp "%DIR%";"%DIR%bio-formats.jar";"%DIR%loci_tools.jar";"%DIR%ome-editor.jar";"%DIR%ome-java.jar";"%DIR%ome-java-deprecated.jar" %PROG% %* 
    3535goto end 
    3636 
  • trunk/tools/formatlist

    r5987 r6182  
    2020elif [ -e "$DIR/loci_tools.jar" ] || [ -e "$DIR/bio-formats.jar" ] 
    2121then 
    22   java -mx512m -cp "$DIR/bio-formats.jar":"$DIR/loci_tools.jar" $PROG "$@" 
     22  java -mx512m -cp "$DIR":"$DIR/bio-formats.jar":"$DIR/loci_tools.jar" $PROG "$@" 
    2323else 
    2424  echo "Required JAR libraries not found. Please download:" 
  • trunk/tools/formatlist.bat

    r5987 r6182  
    2828:found 
    2929rem Library found; try to launch 
    30 java -mx512m -cp "%DIR%bio-formats.jar";"%DIR%loci_tools.jar" %PROG% %* 
     30java -mx512m -cp "%DIR%";"%DIR%bio-formats.jar";"%DIR%loci_tools.jar" %PROG% %* 
    3131goto end 
    3232 
  • trunk/tools/ijview

    r6002 r6182  
    2222  ([ -e "$DIR/loci_tools.jar" ] || [ -e "$DIR/bio-formats.jar" ]) 
    2323then 
    24   java -mx512m -cp \ 
    25     "$DIR/bio-formats.jar":"$DIR/loci_tools.jar":"$DIR/ij.jar" \ 
    26     $PROG "$@" 
     24  java -mx512m -cp "$DIR":"$DIR/bio-formats.jar":"$DIR/loci_tools.jar":"$DIR/ij.jar" $PROG "$@" 
    2725else 
    2826  echo "Required JAR libraries not found. Please download:" 
  • trunk/tools/ijview.bat

    r6002 r6182  
    3030:found 
    3131rem Library found; try to launch 
    32 java -mx512m -cp "%DIR%bio-formats.jar";"%DIR%loci_tools.jar";"%DIR%ij.jar" %PROG% %* 
     32java -mx512m -cp "%DIR%";"%DIR%bio-formats.jar";"%DIR%loci_tools.jar";"%DIR%ij.jar" %PROG% %* 
    3333goto end 
    3434 
  • trunk/tools/log4j.properties

    r6167 r6182  
    33# 
    44 
    5 # A very simple log4j configuration. 
     5# A log4j configuration for the Bio-Formats command line tools. 
    66 
    77# By default, running various main methods in the codebase yields the error: 
     
    1515# And of course, you can edit this file to configure how output is produced. 
    1616 
    17 log4j.rootCategory=DEBUG, stdout 
     17log4j.rootCategory=INFO, stdout 
    1818log4j.appender.stdout=org.apache.log4j.ConsoleAppender 
    1919log4j.appender.stdout.layout=org.apache.log4j.PatternLayout 
     20log4j.appender.stdout.layout.ConversionPattern=%m%n 
    2021#log4j.appender.stdout.layout.ConversionPattern=%d [%t] %-5p %c - %m%n 
  • trunk/tools/notes

    r5987 r6182  
    2222  [ -e "$DIR/ome-notes.jar" ] 
    2323then 
    24   java -mx512m -cp \ 
    25     "$DIR/bio-formats.jar":"$DIR/loci_tools.jar":"$DIR/ome-notes.jar" \ 
    26     $PROG "$@" 
     24  java -mx512m -cp "$DIR":"$DIR/bio-formats.jar":"$DIR/loci_tools.jar":"$DIR/ome-notes.jar" $PROG "$@" 
    2725else 
    2826  echo "Required JAR libraries not found. Please download:" 
  • trunk/tools/notes.bat

    r5987 r6182  
    2929:found 
    3030rem Library found; try to launch 
    31 java -mx512m -cp "%DIR%bio-formats.jar";"%DIR%loci_tools.jar";"%DIR%ome-notes.jar" %PROG% %* 
     31java -mx512m -cp "%DIR%";"%DIR%bio-formats.jar";"%DIR%loci_tools.jar";"%DIR%ome-notes.jar" %PROG% %* 
    3232goto end 
    3333 
  • trunk/tools/omeul

    r5987 r6182  
    2020elif [ -e "$DIR/loci_tools.jar" ] || [ -e "$DIR/bio-formats.jar" ] 
    2121then 
    22   java -mx512m -cp "$DIR/bio-formats.jar":"$DIR/loci_tools.jar" $PROG "$@" 
     22  java -mx512m -cp "$DIR":"$DIR/bio-formats.jar":"$DIR/loci_tools.jar" $PROG "$@" 
    2323else 
    2424  echo "Required JAR libraries not found. Please download:" 
  • trunk/tools/omeul.bat

    r5987 r6182  
    2828:found 
    2929rem Library found; try to launch 
    30 java -mx512m -cp "%DIR%bio-formats.jar";"%DIR%loci_tools.jar" %PROG% %* 
     30java -mx512m -cp "%DIR%";"%DIR%bio-formats.jar";"%DIR%loci_tools.jar" %PROG% %* 
    3131goto end 
    3232 
  • trunk/tools/showinf

    r5987 r6182  
    2121elif [ -e "$DIR/loci_tools.jar" ] || [ -e "$DIR/bio-formats.jar" ] 
    2222then 
    23   java -mx512m -cp "$DIR/bio-formats.jar":"$DIR/loci_tools.jar" $PROG "$@" 
     23  java -mx512m -cp "$DIR":"$DIR/bio-formats.jar":"$DIR/loci_tools.jar" $PROG "$@" 
    2424else 
    2525  echo "Required JAR libraries not found. Please download:" 
  • trunk/tools/showinf.bat

    r5987 r6182  
    2929:found 
    3030rem Library found; try to launch 
    31 java -mx512m -cp "%DIR%bio-formats.jar";"%DIR%loci_tools.jar" %PROG% %* 
     31java -mx512m -cp "%DIR%";"%DIR%bio-formats.jar";"%DIR%loci_tools.jar" %PROG% %* 
    3232goto end 
    3333 
  • trunk/tools/tiffcomment

    r5987 r6182  
    2121elif [ -e "$DIR/loci_tools.jar" ] || [ -e "$DIR/bio-formats.jar" ] 
    2222then 
    23   java -mx512m -cp "$DIR/bio-formats.jar":"$DIR/loci_tools.jar" $PROG "$@" 
     23  java -mx512m -cp "$DIR":"$DIR/bio-formats.jar":"$DIR/loci_tools.jar" $PROG "$@" 
    2424else 
    2525  echo "Required JAR libraries not found. Please download:" 
  • trunk/tools/tiffcomment.bat

    r5987 r6182  
    2929:found 
    3030rem Library found; try to launch 
    31 java -mx512m -cp "%DIR%bio-formats.jar";"%DIR%loci_tools.jar" %PROG% %* 
     31java -mx512m -cp "%DIR%";"%DIR%bio-formats.jar";"%DIR%loci_tools.jar" %PROG% %* 
    3232goto end 
    3333 
  • trunk/tools/xmlindent

    r5987 r6182  
    2020elif [ -e "$DIR/loci_tools.jar" ] || [ -e "$DIR/bio-formats.jar" ] 
    2121then 
    22   java -mx512m -cp "$DIR/bio-formats.jar":"$DIR/loci_tools.jar" $PROG "$@" 
     22  java -mx512m -cp "$DIR":"$DIR/bio-formats.jar":"$DIR/loci_tools.jar" $PROG "$@" 
    2323else 
    2424  echo "Required JAR libraries not found. Please download:" 
  • trunk/tools/xmlindent.bat

    r5987 r6182  
    2828:found 
    2929rem Library found; try to launch 
    30 java -mx512m -cp "%DIR%bio-formats.jar";"%DIR%loci_tools.jar" %PROG% %* 
     30java -mx512m -cp "%DIR%";"%DIR%bio-formats.jar";"%DIR%loci_tools.jar" %PROG% %* 
    3131goto end 
    3232 
  • trunk/tools/xmlvalid

    r5987 r6182  
    2020elif [ -e "$DIR/loci_tools.jar" ] || [ -e "$DIR/bio-formats.jar" ] 
    2121then 
    22   java -mx512m -cp "$DIR/bio-formats.jar":"$DIR/loci_tools.jar" $PROG "$@" 
     22  java -mx512m -cp "$DIR":"$DIR/bio-formats.jar":"$DIR/loci_tools.jar" $PROG "$@" 
    2323else 
    2424  echo "Required JAR libraries not found. Please download:" 
  • trunk/tools/xmlvalid.bat

    r5987 r6182  
    2828:found 
    2929rem Library found; try to launch 
    30 java -mx512m -cp "%DIR%bio-formats.jar";"%DIR%loci_tools.jar" %PROG% %* 
     30java -mx512m -cp "%DIR%";"%DIR%bio-formats.jar";"%DIR%loci_tools.jar" %PROG% %* 
    3131goto end 
    3232 
Note: See TracChangeset for help on using the changeset viewer.