| <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> |
| <!-- NewPage --> |
| <html lang="en"> |
| <head> |
| <!-- Generated by javadoc (1.8.0_121) on Fri Apr 14 22:10:57 PDT 2017 --> |
| <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> |
| <title>VectorBinaryAssign (Mahout Math 0.13.0 API)</title> |
| <meta name="date" content="2017-04-14"> |
| <link rel="stylesheet" type="text/css" href="../../../../stylesheet.css" title="Style"> |
| <script type="text/javascript" src="../../../../script.js"></script> |
| </head> |
| <body> |
| <script type="text/javascript"><!-- |
| try { |
| if (location.href.indexOf('is-external=true') == -1) { |
| parent.document.title="VectorBinaryAssign (Mahout Math 0.13.0 API)"; |
| } |
| } |
| catch(err) { |
| } |
| //--> |
| var methods = {"i0":6,"i1":9,"i2":6,"i3":9,"i4":6}; |
| var tabs = {65535:["t0","All Methods"],1:["t1","Static Methods"],2:["t2","Instance Methods"],4:["t3","Abstract Methods"],8:["t4","Concrete Methods"]}; |
| var altColor = "altColor"; |
| var rowColor = "rowColor"; |
| var tableTab = "tableTab"; |
| var activeTableTab = "activeTableTab"; |
| </script> |
| <noscript> |
| <div>JavaScript is disabled on your browser.</div> |
| </noscript> |
| <!-- ========= START OF TOP NAVBAR ======= --> |
| <div class="topNav"><a name="navbar.top"> |
| <!-- --> |
| </a> |
| <div class="skipNav"><a href="#skip.navbar.top" title="Skip navigation links">Skip navigation links</a></div> |
| <a name="navbar.top.firstrow"> |
| <!-- --> |
| </a> |
| <ul class="navList" title="Navigation"> |
| <li><a href="../../../../overview-summary.html">Overview</a></li> |
| <li><a href="package-summary.html">Package</a></li> |
| <li class="navBarCell1Rev">Class</li> |
| <li><a href="class-use/VectorBinaryAssign.html">Use</a></li> |
| <li><a href="package-tree.html">Tree</a></li> |
| <li><a href="../../../../deprecated-list.html">Deprecated</a></li> |
| <li><a href="../../../../index-all.html">Index</a></li> |
| <li><a href="../../../../help-doc.html">Help</a></li> |
| </ul> |
| </div> |
| <div class="subNav"> |
| <ul class="navList"> |
| <li><a href="../../../../org/apache/mahout/math/VectorBinaryAggregate.AggregateNonzerosIterateThisLookupThat.html" title="class in org.apache.mahout.math"><span class="typeNameLink">Prev Class</span></a></li> |
| <li><a href="../../../../org/apache/mahout/math/VectorBinaryAssign.AssignAllIterateSequentialInplaceUpdates.html" title="class in org.apache.mahout.math"><span class="typeNameLink">Next Class</span></a></li> |
| </ul> |
| <ul class="navList"> |
| <li><a href="../../../../index.html?org/apache/mahout/math/VectorBinaryAssign.html" target="_top">Frames</a></li> |
| <li><a href="VectorBinaryAssign.html" target="_top">No Frames</a></li> |
| </ul> |
| <ul class="navList" id="allclasses_navbar_top"> |
| <li><a href="../../../../allclasses-noframe.html">All Classes</a></li> |
| </ul> |
| <div> |
| <script type="text/javascript"><!-- |
| allClassesLink = document.getElementById("allclasses_navbar_top"); |
| if(window==top) { |
| allClassesLink.style.display = "block"; |
| } |
| else { |
| allClassesLink.style.display = "none"; |
| } |
| //--> |
| </script> |
| </div> |
| <div> |
| <ul class="subNavList"> |
| <li>Summary: </li> |
| <li><a href="#nested.class.summary">Nested</a> | </li> |
| <li><a href="#field.summary">Field</a> | </li> |
| <li><a href="#constructor.summary">Constr</a> | </li> |
| <li><a href="#method.summary">Method</a></li> |
| </ul> |
| <ul class="subNavList"> |
| <li>Detail: </li> |
| <li><a href="#field.detail">Field</a> | </li> |
| <li><a href="#constructor.detail">Constr</a> | </li> |
| <li><a href="#method.detail">Method</a></li> |
| </ul> |
| </div> |
| <a name="skip.navbar.top"> |
| <!-- --> |
| </a></div> |
| <!-- ========= END OF TOP NAVBAR ========= --> |
| <!-- ======== START OF CLASS DATA ======== --> |
| <div class="header"> |
| <div class="subTitle">org.apache.mahout.math</div> |
| <h2 title="Class VectorBinaryAssign" class="title">Class VectorBinaryAssign</h2> |
| </div> |
| <div class="contentContainer"> |
| <ul class="inheritance"> |
| <li><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</a></li> |
| <li> |
| <ul class="inheritance"> |
| <li>org.apache.mahout.math.VectorBinaryAssign</li> |
| </ul> |
| </li> |
| </ul> |
| <div class="description"> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <dl> |
| <dt>Direct Known Subclasses:</dt> |
| <dd><a href="../../../../org/apache/mahout/math/VectorBinaryAssign.AssignAllIterateSequentialInplaceUpdates.html" title="class in org.apache.mahout.math">VectorBinaryAssign.AssignAllIterateSequentialInplaceUpdates</a>, <a href="../../../../org/apache/mahout/math/VectorBinaryAssign.AssignAllIterateSequentialMergeUpdates.html" title="class in org.apache.mahout.math">VectorBinaryAssign.AssignAllIterateSequentialMergeUpdates</a>, <a href="../../../../org/apache/mahout/math/VectorBinaryAssign.AssignAllIterateThatLookupThisInplaceUpdates.html" title="class in org.apache.mahout.math">VectorBinaryAssign.AssignAllIterateThatLookupThisInplaceUpdates</a>, <a href="../../../../org/apache/mahout/math/VectorBinaryAssign.AssignAllIterateThatLookupThisMergeUpdates.html" title="class in org.apache.mahout.math">VectorBinaryAssign.AssignAllIterateThatLookupThisMergeUpdates</a>, <a href="../../../../org/apache/mahout/math/VectorBinaryAssign.AssignAllIterateThisLookupThatInplaceUpdates.html" title="class in org.apache.mahout.math">VectorBinaryAssign.AssignAllIterateThisLookupThatInplaceUpdates</a>, <a href="../../../../org/apache/mahout/math/VectorBinaryAssign.AssignAllIterateThisLookupThatMergeUpdates.html" title="class in org.apache.mahout.math">VectorBinaryAssign.AssignAllIterateThisLookupThatMergeUpdates</a>, <a href="../../../../org/apache/mahout/math/VectorBinaryAssign.AssignAllLoopInplaceUpdates.html" title="class in org.apache.mahout.math">VectorBinaryAssign.AssignAllLoopInplaceUpdates</a>, <a href="../../../../org/apache/mahout/math/VectorBinaryAssign.AssignAllLoopMergeUpdates.html" title="class in org.apache.mahout.math">VectorBinaryAssign.AssignAllLoopMergeUpdates</a>, <a href="../../../../org/apache/mahout/math/VectorBinaryAssign.AssignIterateIntersection.html" title="class in org.apache.mahout.math">VectorBinaryAssign.AssignIterateIntersection</a>, <a href="../../../../org/apache/mahout/math/VectorBinaryAssign.AssignIterateUnionRandomInplaceUpdates.html" title="class in org.apache.mahout.math">VectorBinaryAssign.AssignIterateUnionRandomInplaceUpdates</a>, <a href="../../../../org/apache/mahout/math/VectorBinaryAssign.AssignIterateUnionRandomMergeUpdates.html" title="class in org.apache.mahout.math">VectorBinaryAssign.AssignIterateUnionRandomMergeUpdates</a>, <a href="../../../../org/apache/mahout/math/VectorBinaryAssign.AssignIterateUnionSequentialInplaceUpdates.html" title="class in org.apache.mahout.math">VectorBinaryAssign.AssignIterateUnionSequentialInplaceUpdates</a>, <a href="../../../../org/apache/mahout/math/VectorBinaryAssign.AssignIterateUnionSequentialMergeUpdates.html" title="class in org.apache.mahout.math">VectorBinaryAssign.AssignIterateUnionSequentialMergeUpdates</a>, <a href="../../../../org/apache/mahout/math/VectorBinaryAssign.AssignNonzerosIterateThatLookupThisInplaceUpdates.html" title="class in org.apache.mahout.math">VectorBinaryAssign.AssignNonzerosIterateThatLookupThisInplaceUpdates</a>, <a href="../../../../org/apache/mahout/math/VectorBinaryAssign.AssignNonzerosIterateThatLookupThisMergeUpdates.html" title="class in org.apache.mahout.math">VectorBinaryAssign.AssignNonzerosIterateThatLookupThisMergeUpdates</a>, <a href="../../../../org/apache/mahout/math/VectorBinaryAssign.AssignNonzerosIterateThisLookupThat.html" title="class in org.apache.mahout.math">VectorBinaryAssign.AssignNonzerosIterateThisLookupThat</a></dd> |
| </dl> |
| <hr> |
| <br> |
| <pre>public abstract class <span class="typeNameLabel">VectorBinaryAssign</span> |
| extends <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a></pre> |
| <div class="block">Abstract class encapsulating different algorithms that perform the Vector operations assign(). |
| x.assign(y, f), for x and y Vectors and f a DoubleDouble function: |
| - applies the function f to every element in x and y, f(xi, yi) |
| - assigns xi = f(xi, yi) for all indices i |
| |
| The names of variables, methods and classes used here follow the following conventions: |
| The vector being assigned to (the left hand side) is called this or x. |
| The right hand side is called that or y. |
| The function to be applied is called f. |
| |
| The different algorithms take into account the different characteristics of vector classes: |
| - whether the vectors support sequential iteration (isSequential()) |
| - whether the vectors support constant-time additions (isAddConstantTime()) |
| - what the lookup cost is (getLookupCost()) |
| - what the iterator advancement cost is (getIteratorAdvanceCost()) |
| |
| The names of the actual classes (they're nested in VectorBinaryAssign) describe the used for assignment. |
| The most important optimization is iterating just through the nonzeros (only possible if f(0, 0) = 0). |
| There are 4 main possibilities: |
| - iterating through the nonzeros of just one vector and looking up the corresponding elements in the other |
| - iterating through the intersection of nonzeros (those indices where both vectors have nonzero values) |
| - iterating through the union of nonzeros (those indices where at least one of the vectors has a nonzero value) |
| - iterating through all the elements in some way (either through both at the same time, both one after the other, |
| looking up both, looking up just one). |
| Then, there are two additional sub-possibilities: |
| - if a new value can be added to x in constant time (isAddConstantTime()), the *Inplace updates are used |
| - otherwise (really just for SequentialAccessSparseVectors right now), the *Merge updates are used, where |
| a sorted list of (index, value) pairs is merged into the vector at the end. |
| |
| The internal details are not important and a particular algorithm should generally not be called explicitly. |
| The best one will be selected through assignBest(), which is itself called through Vector.assign(). |
| |
| See https://docs.google.com/document/d/1g1PjUuvjyh2LBdq2_rKLIcUiDbeOORA1sCJiSsz-JVU/edit# for a more detailed |
| explanation.</div> |
| </li> |
| </ul> |
| </div> |
| <div class="summary"> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <!-- ======== NESTED CLASS SUMMARY ======== --> |
| <ul class="blockList"> |
| <li class="blockList"><a name="nested.class.summary"> |
| <!-- --> |
| </a> |
| <h3>Nested Class Summary</h3> |
| <table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Nested Class Summary table, listing nested classes, and an explanation"> |
| <caption><span>Nested Classes</span><span class="tabEnd"> </span></caption> |
| <tr> |
| <th class="colFirst" scope="col">Modifier and Type</th> |
| <th class="colLast" scope="col">Class and Description</th> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><code>static class </code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/mahout/math/VectorBinaryAssign.AssignAllIterateSequentialInplaceUpdates.html" title="class in org.apache.mahout.math">VectorBinaryAssign.AssignAllIterateSequentialInplaceUpdates</a></span></code> </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><code>static class </code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/mahout/math/VectorBinaryAssign.AssignAllIterateSequentialMergeUpdates.html" title="class in org.apache.mahout.math">VectorBinaryAssign.AssignAllIterateSequentialMergeUpdates</a></span></code> </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><code>static class </code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/mahout/math/VectorBinaryAssign.AssignAllIterateThatLookupThisInplaceUpdates.html" title="class in org.apache.mahout.math">VectorBinaryAssign.AssignAllIterateThatLookupThisInplaceUpdates</a></span></code> </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><code>static class </code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/mahout/math/VectorBinaryAssign.AssignAllIterateThatLookupThisMergeUpdates.html" title="class in org.apache.mahout.math">VectorBinaryAssign.AssignAllIterateThatLookupThisMergeUpdates</a></span></code> </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><code>static class </code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/mahout/math/VectorBinaryAssign.AssignAllIterateThisLookupThatInplaceUpdates.html" title="class in org.apache.mahout.math">VectorBinaryAssign.AssignAllIterateThisLookupThatInplaceUpdates</a></span></code> </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><code>static class </code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/mahout/math/VectorBinaryAssign.AssignAllIterateThisLookupThatMergeUpdates.html" title="class in org.apache.mahout.math">VectorBinaryAssign.AssignAllIterateThisLookupThatMergeUpdates</a></span></code> </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><code>static class </code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/mahout/math/VectorBinaryAssign.AssignAllLoopInplaceUpdates.html" title="class in org.apache.mahout.math">VectorBinaryAssign.AssignAllLoopInplaceUpdates</a></span></code> </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><code>static class </code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/mahout/math/VectorBinaryAssign.AssignAllLoopMergeUpdates.html" title="class in org.apache.mahout.math">VectorBinaryAssign.AssignAllLoopMergeUpdates</a></span></code> </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><code>static class </code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/mahout/math/VectorBinaryAssign.AssignIterateIntersection.html" title="class in org.apache.mahout.math">VectorBinaryAssign.AssignIterateIntersection</a></span></code> |
| <div class="block">If f(x, 0) = x and f(0, y) = 0 the zeros in x and y don't matter and we can iterate through the nonzeros |
| in both x and y.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><code>static class </code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/mahout/math/VectorBinaryAssign.AssignIterateUnionRandomInplaceUpdates.html" title="class in org.apache.mahout.math">VectorBinaryAssign.AssignIterateUnionRandomInplaceUpdates</a></span></code> |
| <div class="block">If f(0, 0) = 0 we can iterate through the nonzeros in either x or y.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><code>static class </code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/mahout/math/VectorBinaryAssign.AssignIterateUnionRandomMergeUpdates.html" title="class in org.apache.mahout.math">VectorBinaryAssign.AssignIterateUnionRandomMergeUpdates</a></span></code> |
| <div class="block">If f(0, 0) = 0 we can iterate through the nonzeros in either x or y.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><code>static class </code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/mahout/math/VectorBinaryAssign.AssignIterateUnionSequentialInplaceUpdates.html" title="class in org.apache.mahout.math">VectorBinaryAssign.AssignIterateUnionSequentialInplaceUpdates</a></span></code> |
| <div class="block">If f(0, 0) = 0 we can iterate through the nonzeros in either x or y.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><code>static class </code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/mahout/math/VectorBinaryAssign.AssignIterateUnionSequentialMergeUpdates.html" title="class in org.apache.mahout.math">VectorBinaryAssign.AssignIterateUnionSequentialMergeUpdates</a></span></code> |
| <div class="block">If f(0, 0) = 0 we can iterate through the nonzeros in either x or y.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><code>static class </code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/mahout/math/VectorBinaryAssign.AssignNonzerosIterateThatLookupThisInplaceUpdates.html" title="class in org.apache.mahout.math">VectorBinaryAssign.AssignNonzerosIterateThatLookupThisInplaceUpdates</a></span></code> |
| <div class="block">If f(x, 0) = x, the zeros in y don't matter and we can simply iterate through the nonzeros of y.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><code>static class </code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/mahout/math/VectorBinaryAssign.AssignNonzerosIterateThatLookupThisMergeUpdates.html" title="class in org.apache.mahout.math">VectorBinaryAssign.AssignNonzerosIterateThatLookupThisMergeUpdates</a></span></code> |
| <div class="block">If f(x, 0) = x, the zeros in y don't matter and we can simply iterate through the nonzeros of y.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><code>static class </code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/mahout/math/VectorBinaryAssign.AssignNonzerosIterateThisLookupThat.html" title="class in org.apache.mahout.math">VectorBinaryAssign.AssignNonzerosIterateThisLookupThat</a></span></code> |
| <div class="block">If f(0, y) = 0, the zeros in x don't matter and we can simply iterate through the nonzeros of x.</div> |
| </td> |
| </tr> |
| </table> |
| </li> |
| </ul> |
| <!-- =========== FIELD SUMMARY =========== --> |
| <ul class="blockList"> |
| <li class="blockList"><a name="field.summary"> |
| <!-- --> |
| </a> |
| <h3>Field Summary</h3> |
| <table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Field Summary table, listing fields, and an explanation"> |
| <caption><span>Fields</span><span class="tabEnd"> </span></caption> |
| <tr> |
| <th class="colFirst" scope="col">Modifier and Type</th> |
| <th class="colLast" scope="col">Field and Description</th> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><code>static <a href="../../../../org/apache/mahout/math/VectorBinaryAssign.html" title="class in org.apache.mahout.math">VectorBinaryAssign</a>[]</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/mahout/math/VectorBinaryAssign.html#OPERATIONS">OPERATIONS</a></span></code> </td> |
| </tr> |
| </table> |
| </li> |
| </ul> |
| <!-- ======== CONSTRUCTOR SUMMARY ======== --> |
| <ul class="blockList"> |
| <li class="blockList"><a name="constructor.summary"> |
| <!-- --> |
| </a> |
| <h3>Constructor Summary</h3> |
| <table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Constructor Summary table, listing constructors, and an explanation"> |
| <caption><span>Constructors</span><span class="tabEnd"> </span></caption> |
| <tr> |
| <th class="colOne" scope="col">Constructor and Description</th> |
| </tr> |
| <tr class="altColor"> |
| <td class="colOne"><code><span class="memberNameLink"><a href="../../../../org/apache/mahout/math/VectorBinaryAssign.html#VectorBinaryAssign--">VectorBinaryAssign</a></span>()</code> </td> |
| </tr> |
| </table> |
| </li> |
| </ul> |
| <!-- ========== METHOD SUMMARY =========== --> |
| <ul class="blockList"> |
| <li class="blockList"><a name="method.summary"> |
| <!-- --> |
| </a> |
| <h3>Method Summary</h3> |
| <table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Method Summary table, listing methods, and an explanation"> |
| <caption><span id="t0" class="activeTableTab"><span>All Methods</span><span class="tabEnd"> </span></span><span id="t1" class="tableTab"><span><a href="javascript:show(1);">Static Methods</a></span><span class="tabEnd"> </span></span><span id="t2" class="tableTab"><span><a href="javascript:show(2);">Instance Methods</a></span><span class="tabEnd"> </span></span><span id="t3" class="tableTab"><span><a href="javascript:show(4);">Abstract Methods</a></span><span class="tabEnd"> </span></span><span id="t4" class="tableTab"><span><a href="javascript:show(8);">Concrete Methods</a></span><span class="tabEnd"> </span></span></caption> |
| <tr> |
| <th class="colFirst" scope="col">Modifier and Type</th> |
| <th class="colLast" scope="col">Method and Description</th> |
| </tr> |
| <tr id="i0" class="altColor"> |
| <td class="colFirst"><code>abstract <a href="../../../../org/apache/mahout/math/Vector.html" title="interface in org.apache.mahout.math">Vector</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/mahout/math/VectorBinaryAssign.html#assign-org.apache.mahout.math.Vector-org.apache.mahout.math.Vector-org.apache.mahout.math.function.DoubleDoubleFunction-">assign</a></span>(<a href="../../../../org/apache/mahout/math/Vector.html" title="interface in org.apache.mahout.math">Vector</a> x, |
| <a href="../../../../org/apache/mahout/math/Vector.html" title="interface in org.apache.mahout.math">Vector</a> y, |
| <a href="../../../../org/apache/mahout/math/function/DoubleDoubleFunction.html" title="class in org.apache.mahout.math.function">DoubleDoubleFunction</a> f)</code> |
| <div class="block">Main method that applies f to x and y component-wise assigning the results to x.</div> |
| </td> |
| </tr> |
| <tr id="i1" class="rowColor"> |
| <td class="colFirst"><code>static <a href="../../../../org/apache/mahout/math/Vector.html" title="interface in org.apache.mahout.math">Vector</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/mahout/math/VectorBinaryAssign.html#assignBest-org.apache.mahout.math.Vector-org.apache.mahout.math.Vector-org.apache.mahout.math.function.DoubleDoubleFunction-">assignBest</a></span>(<a href="../../../../org/apache/mahout/math/Vector.html" title="interface in org.apache.mahout.math">Vector</a> x, |
| <a href="../../../../org/apache/mahout/math/Vector.html" title="interface in org.apache.mahout.math">Vector</a> y, |
| <a href="../../../../org/apache/mahout/math/function/DoubleDoubleFunction.html" title="class in org.apache.mahout.math.function">DoubleDoubleFunction</a> f)</code> |
| <div class="block">This is the method that should be used when assigning.</div> |
| </td> |
| </tr> |
| <tr id="i2" class="altColor"> |
| <td class="colFirst"><code>abstract double</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/mahout/math/VectorBinaryAssign.html#estimateCost-org.apache.mahout.math.Vector-org.apache.mahout.math.Vector-org.apache.mahout.math.function.DoubleDoubleFunction-">estimateCost</a></span>(<a href="../../../../org/apache/mahout/math/Vector.html" title="interface in org.apache.mahout.math">Vector</a> x, |
| <a href="../../../../org/apache/mahout/math/Vector.html" title="interface in org.apache.mahout.math">Vector</a> y, |
| <a href="../../../../org/apache/mahout/math/function/DoubleDoubleFunction.html" title="class in org.apache.mahout.math.function">DoubleDoubleFunction</a> f)</code> |
| <div class="block">Estimates the cost of using this algorithm to compute the assignment.</div> |
| </td> |
| </tr> |
| <tr id="i3" class="rowColor"> |
| <td class="colFirst"><code>static <a href="../../../../org/apache/mahout/math/VectorBinaryAssign.html" title="class in org.apache.mahout.math">VectorBinaryAssign</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/mahout/math/VectorBinaryAssign.html#getBestOperation-org.apache.mahout.math.Vector-org.apache.mahout.math.Vector-org.apache.mahout.math.function.DoubleDoubleFunction-">getBestOperation</a></span>(<a href="../../../../org/apache/mahout/math/Vector.html" title="interface in org.apache.mahout.math">Vector</a> x, |
| <a href="../../../../org/apache/mahout/math/Vector.html" title="interface in org.apache.mahout.math">Vector</a> y, |
| <a href="../../../../org/apache/mahout/math/function/DoubleDoubleFunction.html" title="class in org.apache.mahout.math.function">DoubleDoubleFunction</a> f)</code> |
| <div class="block">The best operation is the least expensive valid one.</div> |
| </td> |
| </tr> |
| <tr id="i4" class="altColor"> |
| <td class="colFirst"><code>abstract boolean</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/mahout/math/VectorBinaryAssign.html#isValid-org.apache.mahout.math.Vector-org.apache.mahout.math.Vector-org.apache.mahout.math.function.DoubleDoubleFunction-">isValid</a></span>(<a href="../../../../org/apache/mahout/math/Vector.html" title="interface in org.apache.mahout.math">Vector</a> x, |
| <a href="../../../../org/apache/mahout/math/Vector.html" title="interface in org.apache.mahout.math">Vector</a> y, |
| <a href="../../../../org/apache/mahout/math/function/DoubleDoubleFunction.html" title="class in org.apache.mahout.math.function">DoubleDoubleFunction</a> f)</code> |
| <div class="block">Returns true iff we can use this algorithm to apply f to x and y component-wise and assign the result to x.</div> |
| </td> |
| </tr> |
| </table> |
| <ul class="blockList"> |
| <li class="blockList"><a name="methods.inherited.from.class.java.lang.Object"> |
| <!-- --> |
| </a> |
| <h3>Methods inherited from class java.lang.<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a></h3> |
| <code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#clone--" title="class or interface in java.lang">clone</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#equals-java.lang.Object-" title="class or interface in java.lang">equals</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#finalize--" title="class or interface in java.lang">finalize</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#getClass--" title="class or interface in java.lang">getClass</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#hashCode--" title="class or interface in java.lang">hashCode</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#notify--" title="class or interface in java.lang">notify</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#notifyAll--" title="class or interface in java.lang">notifyAll</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#toString--" title="class or interface in java.lang">toString</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#wait--" title="class or interface in java.lang">wait</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#wait-long-" title="class or interface in java.lang">wait</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#wait-long-int-" title="class or interface in java.lang">wait</a></code></li> |
| </ul> |
| </li> |
| </ul> |
| </li> |
| </ul> |
| </div> |
| <div class="details"> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <!-- ============ FIELD DETAIL =========== --> |
| <ul class="blockList"> |
| <li class="blockList"><a name="field.detail"> |
| <!-- --> |
| </a> |
| <h3>Field Detail</h3> |
| <a name="OPERATIONS"> |
| <!-- --> |
| </a> |
| <ul class="blockListLast"> |
| <li class="blockList"> |
| <h4>OPERATIONS</h4> |
| <pre>public static final <a href="../../../../org/apache/mahout/math/VectorBinaryAssign.html" title="class in org.apache.mahout.math">VectorBinaryAssign</a>[] OPERATIONS</pre> |
| </li> |
| </ul> |
| </li> |
| </ul> |
| <!-- ========= CONSTRUCTOR DETAIL ======== --> |
| <ul class="blockList"> |
| <li class="blockList"><a name="constructor.detail"> |
| <!-- --> |
| </a> |
| <h3>Constructor Detail</h3> |
| <a name="VectorBinaryAssign--"> |
| <!-- --> |
| </a> |
| <ul class="blockListLast"> |
| <li class="blockList"> |
| <h4>VectorBinaryAssign</h4> |
| <pre>public VectorBinaryAssign()</pre> |
| </li> |
| </ul> |
| </li> |
| </ul> |
| <!-- ============ METHOD DETAIL ========== --> |
| <ul class="blockList"> |
| <li class="blockList"><a name="method.detail"> |
| <!-- --> |
| </a> |
| <h3>Method Detail</h3> |
| <a name="isValid-org.apache.mahout.math.Vector-org.apache.mahout.math.Vector-org.apache.mahout.math.function.DoubleDoubleFunction-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>isValid</h4> |
| <pre>public abstract boolean isValid(<a href="../../../../org/apache/mahout/math/Vector.html" title="interface in org.apache.mahout.math">Vector</a> x, |
| <a href="../../../../org/apache/mahout/math/Vector.html" title="interface in org.apache.mahout.math">Vector</a> y, |
| <a href="../../../../org/apache/mahout/math/function/DoubleDoubleFunction.html" title="class in org.apache.mahout.math.function">DoubleDoubleFunction</a> f)</pre> |
| <div class="block">Returns true iff we can use this algorithm to apply f to x and y component-wise and assign the result to x.</div> |
| </li> |
| </ul> |
| <a name="estimateCost-org.apache.mahout.math.Vector-org.apache.mahout.math.Vector-org.apache.mahout.math.function.DoubleDoubleFunction-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>estimateCost</h4> |
| <pre>public abstract double estimateCost(<a href="../../../../org/apache/mahout/math/Vector.html" title="interface in org.apache.mahout.math">Vector</a> x, |
| <a href="../../../../org/apache/mahout/math/Vector.html" title="interface in org.apache.mahout.math">Vector</a> y, |
| <a href="../../../../org/apache/mahout/math/function/DoubleDoubleFunction.html" title="class in org.apache.mahout.math.function">DoubleDoubleFunction</a> f)</pre> |
| <div class="block">Estimates the cost of using this algorithm to compute the assignment. The algorithm is assumed to be valid.</div> |
| </li> |
| </ul> |
| <a name="assign-org.apache.mahout.math.Vector-org.apache.mahout.math.Vector-org.apache.mahout.math.function.DoubleDoubleFunction-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>assign</h4> |
| <pre>public abstract <a href="../../../../org/apache/mahout/math/Vector.html" title="interface in org.apache.mahout.math">Vector</a> assign(<a href="../../../../org/apache/mahout/math/Vector.html" title="interface in org.apache.mahout.math">Vector</a> x, |
| <a href="../../../../org/apache/mahout/math/Vector.html" title="interface in org.apache.mahout.math">Vector</a> y, |
| <a href="../../../../org/apache/mahout/math/function/DoubleDoubleFunction.html" title="class in org.apache.mahout.math.function">DoubleDoubleFunction</a> f)</pre> |
| <div class="block">Main method that applies f to x and y component-wise assigning the results to x. It returns the modified vector, |
| x.</div> |
| </li> |
| </ul> |
| <a name="getBestOperation-org.apache.mahout.math.Vector-org.apache.mahout.math.Vector-org.apache.mahout.math.function.DoubleDoubleFunction-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getBestOperation</h4> |
| <pre>public static <a href="../../../../org/apache/mahout/math/VectorBinaryAssign.html" title="class in org.apache.mahout.math">VectorBinaryAssign</a> getBestOperation(<a href="../../../../org/apache/mahout/math/Vector.html" title="interface in org.apache.mahout.math">Vector</a> x, |
| <a href="../../../../org/apache/mahout/math/Vector.html" title="interface in org.apache.mahout.math">Vector</a> y, |
| <a href="../../../../org/apache/mahout/math/function/DoubleDoubleFunction.html" title="class in org.apache.mahout.math.function">DoubleDoubleFunction</a> f)</pre> |
| <div class="block">The best operation is the least expensive valid one.</div> |
| </li> |
| </ul> |
| <a name="assignBest-org.apache.mahout.math.Vector-org.apache.mahout.math.Vector-org.apache.mahout.math.function.DoubleDoubleFunction-"> |
| <!-- --> |
| </a> |
| <ul class="blockListLast"> |
| <li class="blockList"> |
| <h4>assignBest</h4> |
| <pre>public static <a href="../../../../org/apache/mahout/math/Vector.html" title="interface in org.apache.mahout.math">Vector</a> assignBest(<a href="../../../../org/apache/mahout/math/Vector.html" title="interface in org.apache.mahout.math">Vector</a> x, |
| <a href="../../../../org/apache/mahout/math/Vector.html" title="interface in org.apache.mahout.math">Vector</a> y, |
| <a href="../../../../org/apache/mahout/math/function/DoubleDoubleFunction.html" title="class in org.apache.mahout.math.function">DoubleDoubleFunction</a> f)</pre> |
| <div class="block">This is the method that should be used when assigning. It selects the best algorithm and applies it. |
| Note that it does NOT invalidate the cached length of the Vector and should only be used through the wrapprs |
| in AbstractVector.</div> |
| </li> |
| </ul> |
| </li> |
| </ul> |
| </li> |
| </ul> |
| </div> |
| </div> |
| <!-- ========= END OF CLASS DATA ========= --> |
| <!-- ======= START OF BOTTOM NAVBAR ====== --> |
| <div class="bottomNav"><a name="navbar.bottom"> |
| <!-- --> |
| </a> |
| <div class="skipNav"><a href="#skip.navbar.bottom" title="Skip navigation links">Skip navigation links</a></div> |
| <a name="navbar.bottom.firstrow"> |
| <!-- --> |
| </a> |
| <ul class="navList" title="Navigation"> |
| <li><a href="../../../../overview-summary.html">Overview</a></li> |
| <li><a href="package-summary.html">Package</a></li> |
| <li class="navBarCell1Rev">Class</li> |
| <li><a href="class-use/VectorBinaryAssign.html">Use</a></li> |
| <li><a href="package-tree.html">Tree</a></li> |
| <li><a href="../../../../deprecated-list.html">Deprecated</a></li> |
| <li><a href="../../../../index-all.html">Index</a></li> |
| <li><a href="../../../../help-doc.html">Help</a></li> |
| </ul> |
| </div> |
| <div class="subNav"> |
| <ul class="navList"> |
| <li><a href="../../../../org/apache/mahout/math/VectorBinaryAggregate.AggregateNonzerosIterateThisLookupThat.html" title="class in org.apache.mahout.math"><span class="typeNameLink">Prev Class</span></a></li> |
| <li><a href="../../../../org/apache/mahout/math/VectorBinaryAssign.AssignAllIterateSequentialInplaceUpdates.html" title="class in org.apache.mahout.math"><span class="typeNameLink">Next Class</span></a></li> |
| </ul> |
| <ul class="navList"> |
| <li><a href="../../../../index.html?org/apache/mahout/math/VectorBinaryAssign.html" target="_top">Frames</a></li> |
| <li><a href="VectorBinaryAssign.html" target="_top">No Frames</a></li> |
| </ul> |
| <ul class="navList" id="allclasses_navbar_bottom"> |
| <li><a href="../../../../allclasses-noframe.html">All Classes</a></li> |
| </ul> |
| <div> |
| <script type="text/javascript"><!-- |
| allClassesLink = document.getElementById("allclasses_navbar_bottom"); |
| if(window==top) { |
| allClassesLink.style.display = "block"; |
| } |
| else { |
| allClassesLink.style.display = "none"; |
| } |
| //--> |
| </script> |
| </div> |
| <div> |
| <ul class="subNavList"> |
| <li>Summary: </li> |
| <li><a href="#nested.class.summary">Nested</a> | </li> |
| <li><a href="#field.summary">Field</a> | </li> |
| <li><a href="#constructor.summary">Constr</a> | </li> |
| <li><a href="#method.summary">Method</a></li> |
| </ul> |
| <ul class="subNavList"> |
| <li>Detail: </li> |
| <li><a href="#field.detail">Field</a> | </li> |
| <li><a href="#constructor.detail">Constr</a> | </li> |
| <li><a href="#method.detail">Method</a></li> |
| </ul> |
| </div> |
| <a name="skip.navbar.bottom"> |
| <!-- --> |
| </a></div> |
| <!-- ======== END OF BOTTOM NAVBAR ======= --> |
| <p class="legalCopy"><small>Copyright © 2008–2017 <a href="http://www.apache.org/">The Apache Software Foundation</a>. All rights reserved.</small></p> |
| </body> |
| </html> |