Package org.terrier.compression

Examples of org.terrier.compression.BitIn.readUnary()


      final BitIn file = this.file[pointer.getFileNumber()].readReset(pointer.getOffset(), pointer.getOffsetBits());
      int[][] documentTerms = null;
      if (loadTagInformation) { //if there are tag information to process     
        documentTerms = new int[2+fieldCount][count];
        documentTerms[0][0] = file.readGamma() - 1;
        documentTerms[1][0] = file.readUnary();
        for (int f = 0; f < fieldCount; f++) {
          documentTerms[2+f][0] = file.readUnary() - 1;
        }
       
        for (int i = 1; i < count; i++) {         
View Full Code Here


      if (loadTagInformation) { //if there are tag information to process     
        documentTerms = new int[2+fieldCount][count];
        documentTerms[0][0] = file.readGamma() - 1;
        documentTerms[1][0] = file.readUnary();
        for (int f = 0; f < fieldCount; f++) {
          documentTerms[2+f][0] = file.readUnary() - 1;
        }
       
        for (int i = 1; i < count; i++) {         
          documentTerms[0][i] = file.readGamma() + documentTerms[0][i - 1];
          documentTerms[1][i] = file.readUnary();
View Full Code Here

          documentTerms[2+f][0] = file.readUnary() - 1;
        }
       
        for (int i = 1; i < count; i++) {         
          documentTerms[0][i] = file.readGamma() + documentTerms[0][i - 1];
          documentTerms[1][i] = file.readUnary();
          for (int f = 0; f < fieldCount; f++) {
            documentTerms[2+f][i] = file.readUnary() - 1;
          }
        }       
      } else { //no tag information to process         
View Full Code Here

       
        for (int i = 1; i < count; i++) {         
          documentTerms[0][i] = file.readGamma() + documentTerms[0][i - 1];
          documentTerms[1][i] = file.readUnary();
          for (int f = 0; f < fieldCount; f++) {
            documentTerms[2+f][i] = file.readUnary() - 1;
          }
        }       
      } else { //no tag information to process         
        documentTerms = new int[2][count];
        //new   
View Full Code Here

        }       
      } else { //no tag information to process         
        documentTerms = new int[2][count];
        //new   
        documentTerms[0][0] = file.readGamma() - 1;
        documentTerms[1][0] = file.readUnary();
        for(int i = 1; i < count; i++){              
          documentTerms[0][i] = file.readGamma() + documentTerms[0][i - 1];
          documentTerms[1][i] = file.readUnary();
        }
      }
View Full Code Here

        //new   
        documentTerms[0][0] = file.readGamma() - 1;
        documentTerms[1][0] = file.readUnary();
        for(int i = 1; i < count; i++){              
          documentTerms[0][i] = file.readGamma() + documentTerms[0][i - 1];
          documentTerms[1][i] = file.readUnary();
        }
      }
      file.close();
      return documentTerms;
    } catch (IOException ioe) {
View Full Code Here

      final BitIn file = this.file[pointer.getFileNumber()].readReset(pointer.getOffset(), pointer.getOffsetBits());
      int[][] documentTerms = null;
      if (loadTagInformation) { //if there are tag information to process     
        documentTerms = new int[2+fieldCount][count];
        documentTerms[0][0] = file.readGamma() - 1;
        documentTerms[1][0] = file.readUnary();
        for (int f = 0; f < fieldCount; f++) {
          documentTerms[2+f][0] = file.readUnary() - 1;
        }       

        for (int i = 1; i < count; i++) {         
View Full Code Here

      if (loadTagInformation) { //if there are tag information to process     
        documentTerms = new int[2+fieldCount][count];
        documentTerms[0][0] = file.readGamma() - 1;
        documentTerms[1][0] = file.readUnary();
        for (int f = 0; f < fieldCount; f++) {
          documentTerms[2+f][0] = file.readUnary() - 1;
        }       

        for (int i = 1; i < count; i++) {         
          documentTerms[0][i= file.readGamma() + documentTerms[0][i - 1];
          documentTerms[1][i= file.readUnary();
View Full Code Here

          documentTerms[2+f][0] = file.readUnary() - 1;
        }       

        for (int i = 1; i < count; i++) {         
          documentTerms[0][i= file.readGamma() + documentTerms[0][i - 1];
          documentTerms[1][i= file.readUnary();
          for (int f = 0; f < fieldCount; f++) {
            documentTerms[2+f][i] = file.readUnary() - 1;
          }
        }       
      } else { //no tag information to process         
View Full Code Here

        for (int i = 1; i < count; i++) {         
          documentTerms[0][i= file.readGamma() + documentTerms[0][i - 1];
          documentTerms[1][i= file.readUnary();
          for (int f = 0; f < fieldCount; f++) {
            documentTerms[2+f][i] = file.readUnary() - 1;
          }
        }       
      } else { //no tag information to process         
        documentTerms = new int[2][count];
        //new   
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.