Examples of trimToSize()


Examples of org.apache.mahout.math.list.IntArrayList.trimToSize()

      if (condition.apply(viewSlice(i))) {
        matches.add(i);
      }
    }

    matches.trimToSize();
    return viewSelection(matches.elements(), null, null); // take all rows and columns
  }

  /**
   * Construct and returns a new selection view.
View Full Code Here

Examples of org.apache.mahout.math.list.IntArrayList.trimToSize()

      if (condition.apply(viewRow(i))) {
        matches.add(i);
      }
    }

    matches.trimToSize();
    return viewSelection(matches.elements(), null); // take all columns
  }

  /**
   * Construct and returns a new selection view.
View Full Code Here

Examples of org.dcm4che3.data.Attributes.trimToSize()

    public Attributes readDataset(int len, int stopTag) throws IOException {
        handler.startDataset(this);
        readFileMetaInformation();
        Attributes attrs = new Attributes(bigEndian, 64);
        readAttributes(attrs, len, stopTag);
        attrs.trimToSize();
        handler.endDataset(this);
        return attrs;
    }

    public Attributes readFileMetaInformation() throws IOException {
View Full Code Here

Examples of org.dcm4che3.data.Fragments.trimToSize()

                skipAttribute(UNEXPECTED_ATTRIBUTE);
        }
        if (frags.isEmpty())
            attrs.setNull(fragsTag, vr);
        else {
            frags.trimToSize();
            attrs.setValue(fragsTag, vr, frags);
        }
    }

    public byte[] readValue() throws IOException {
View Full Code Here

Examples of org.dcm4che3.data.Sequence.trimToSize()

                skipAttribute(UNEXPECTED_ATTRIBUTE);
        }
        if (seq.isEmpty())
            attrs.setNull(sqtag, VR.SQ);
        else
            seq.trimToSize();
    }

    private void addItemPointer(int sqtag, String privateCreator, int itemIndex) {
        if (itemPointers == null)
            itemPointers = new ArrayList<ItemPointer>(8);
View Full Code Here

Examples of weka.core.FastVector.trimToSize()

      }
      m_DocsCounts[idx]=docsCount;
    }

    // Trim vector and set instance variables
    attributes.trimToSize();
    m_Dictionary = newDictionary;
    m_NumInstances = getInputFormat().numInstances();

    // Set the filter's output format
    Instances outputFormat = new Instances(getInputFormat().relationName(),
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.