Details

    • Type: New Feature New Feature
    • Status: Closed
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: 0.6
    • Fix Version/s: 0.6
    • Labels:
      None

      Description

      I'm thinking to add org.apache.mahout.cf.taste.impl.similarity.jdbc.SQL92JDBCItemSimilarity. It would directly extends AbstractJDBCItemSimilarity. Lots of code would be copied from MySQLJDBCItemSimilarity.

      Any comments/suggestions before I starts the patch?

      1. SQL92.patch
        7 kB
        Daniel Xiaodan Zhou

        Activity

        Daniel Xiaodan Zhou created issue -
        Hide
        Sean Owen added a comment -

        Sounds good to me, go for it.

        Show
        Sean Owen added a comment - Sounds good to me, go for it.
        Hide
        Daniel Xiaodan Zhou added a comment -

        Patch attached.

        Looks like the recent Log-likelihood code breaks unit test, so I'm not able test the patch in mvn. But the patch should be just fine.

        Show
        Daniel Xiaodan Zhou added a comment - Patch attached. Looks like the recent Log-likelihood code breaks unit test, so I'm not able test the patch in mvn. But the patch should be just fine.
        Daniel Xiaodan Zhou made changes -
        Field Original Value New Value
        Attachment SQL92.patch [ 12483766 ]
        Hide
        Sean Owen added a comment -

        How is this different from the MySQL implementation? it looks identical unless I'm missing something.

        Not sure what you mean about the test; all pass in HEAD now and there was no breakage before or after the change.

        Show
        Sean Owen added a comment - How is this different from the MySQL implementation? it looks identical unless I'm missing something. Not sure what you mean about the test; all pass in HEAD now and there was no breakage before or after the change.
        Hide
        Daniel Xiaodan Zhou added a comment -

        MySQL overrides getFetchSize(). SQL92 doesn't override anything, just simply extends from the Abstract class and implements the constructors.

        If HEAD works, that's fine. When I ran my local mvn, it didn't succeed (some of the unit tests in loglikelihood code broke).

        Show
        Daniel Xiaodan Zhou added a comment - MySQL overrides getFetchSize(). SQL92 doesn't override anything, just simply extends from the Abstract class and implements the constructors. If HEAD works, that's fine. When I ran my local mvn, it didn't succeed (some of the unit tests in loglikelihood code broke).
        Hide
        Sean Owen added a comment -

        OK in that case, maybe the current class should be renamed and then make a new MySQL implementation that extends it ? would that work?

        Show
        Sean Owen added a comment - OK in that case, maybe the current class should be renamed and then make a new MySQL implementation that extends it ? would that work?
        Hide
        Daniel Xiaodan Zhou added a comment -

        "the current class should be renamed" – Do you mean to rename SQL92JDBCItemSimilarity or AbstractJDBCItemSimilarity? The current patch follows the design of JDBCDataModel.

        Show
        Daniel Xiaodan Zhou added a comment - "the current class should be renamed" – Do you mean to rename SQL92JDBCItemSimilarity or AbstractJDBCItemSimilarity? The current patch follows the design of JDBCDataModel.
        Hide
        Sean Owen added a comment -

        I just mean that the current MySQL class is really what should be called SQL92 – and then push that call to getFetchSize() down into a subclass called MySQL. It just avoids some of the copy-and-paste here. In the end, you have the same classes with same behavior.

        Show
        Sean Owen added a comment - I just mean that the current MySQL class is really what should be called SQL92 – and then push that call to getFetchSize() down into a subclass called MySQL. It just avoids some of the copy-and-paste here. In the end, you have the same classes with same behavior.
        Sean Owen made changes -
        Status Open [ 1 ] Resolved [ 5 ]
        Resolution Fixed [ 1 ]
        Hide
        Hudson added a comment -

        Integrated in Mahout-Quality #906 (See https://builds.apache.org/job/Mahout-Quality/906/)
        MAHOUT-740 SQL92 implementation for similarities

        srowen : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1139728
        Files :

        • /mahout/trunk/integration/src/main/java/org/apache/mahout/cf/taste/impl/similarity/jdbc/SQL92JDBCInMemoryItemSimilarity.java
        • /mahout/trunk/integration/src/main/java/org/apache/mahout/cf/taste/impl/similarity/jdbc/MySQLJDBCInMemoryItemSimilarity.java
        • /mahout/trunk/integration/src/main/java/org/apache/mahout/cf/taste/impl/similarity/jdbc/SQL92JDBCItemSimilarity.java
        • /mahout/trunk/integration/src/main/java/org/apache/mahout/cf/taste/impl/similarity/jdbc/MySQLJDBCItemSimilarity.java
        Show
        Hudson added a comment - Integrated in Mahout-Quality #906 (See https://builds.apache.org/job/Mahout-Quality/906/ ) MAHOUT-740 SQL92 implementation for similarities srowen : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1139728 Files : /mahout/trunk/integration/src/main/java/org/apache/mahout/cf/taste/impl/similarity/jdbc/SQL92JDBCInMemoryItemSimilarity.java /mahout/trunk/integration/src/main/java/org/apache/mahout/cf/taste/impl/similarity/jdbc/MySQLJDBCInMemoryItemSimilarity.java /mahout/trunk/integration/src/main/java/org/apache/mahout/cf/taste/impl/similarity/jdbc/SQL92JDBCItemSimilarity.java /mahout/trunk/integration/src/main/java/org/apache/mahout/cf/taste/impl/similarity/jdbc/MySQLJDBCItemSimilarity.java
        Sean Owen made changes -
        Status Resolved [ 5 ] Closed [ 6 ]

          People

          • Assignee:
            Sean Owen
            Reporter:
            Daniel Xiaodan Zhou
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development