<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<meta name="Generator" content="Microsoft Exchange Server">
<!-- converted from text --><style><!-- .EmailQuote { margin-left: 1pt; padding-left: 4pt; border-left: #800000 2px solid; } --></style>
</head>
<body>
<meta name="x_Generator" content="Microsoft Word 15 (filtered medium)">
<style>
<!--
p.x_MsoNormal, li.x_MsoNormal, div.x_MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri",sans-serif}
a:x_link, span.x_MsoHyperlink
        {color:blue;
        text-decoration:underline}
a:x_visited, span.x_MsoHyperlinkFollowed
        {color:#954F72;
        text-decoration:underline}
.x_MsoChpDefault
        {}
div.x_WordSection1
        {}
-->
</style>
<div lang="EN-US" link="blue" vlink="#954F72">
<div class="x_WordSection1">
<p class="x_MsoNormal">Dear Titus,</p>
<p class="x_MsoNormal">Great. This solved it.</p>
<p class="x_MsoNormal">Thanks,</p>
<p class="x_MsoNormal">Bogdan</p>
<div style="border:none; border-top:solid #E1E1E1 1.0pt; padding:3.0pt 0in 0in 0in">
<p class="x_MsoNormal" style="border:none; padding:0in"><b>From: </b><a href="mailto:ctbrown@ucdavis.edu">C. Titus Brown</a><br>
<b>Sent: </b>Wednesday, December 7, 2016 8:33 PM<br>
<b>To: </b><a href="mailto:bbintu@fas.harvard.edu">Bintu, Bogdan</a><br>
<b>Cc: </b><a href="mailto:khmer@lists.idyll.org">khmer@lists.idyll.org</a><br>
<b>Subject: </b>Re: [khmer] Unique reverse-complement</p>
</div>
<p class="x_MsoNormal">&nbsp;</p>
</div>
</div>
<font size="2"><span style="font-size:10pt;">
<div class="PlainText">Hi Bogdan,<br>
<br>
apparently we changed things in some of our Makefile refactoring -- since<br>
we don't test this regularly, it went unnoticed!<br>
<br>
A &quot;proper&quot; fix will have to wait, but for now you can modify lib/kmer_hash.hh<br>
like so:<br>
<br>
% diff --git a/lib/kmer_hash.hh b/lib/kmer_hash.hh<br>
----<br>
index 1c6c86f..5b4f5d3 100644<br>
--- a/lib/kmer_hash.hh<br>
&#43;&#43;&#43; b/lib/kmer_hash.hh<br>
@@ -87,11 &#43;87,7 @@ Contact: khmer-project@idyll.org<br>
&nbsp;#endif<br>
&nbsp;<br>
&nbsp;// choose wisely between forward and rev comp.<br>
-#ifndef NO_UNIQUE_RC<br>
-#define uniqify_rc(f, r) ((f) &lt; (r) ? (f) : (r))<br>
-#else<br>
&nbsp;#define uniqify_rc(f,r)(f)<br>
-#endif<br>
&nbsp;<br>
&nbsp;<br>
&nbsp;namespace khmer<br>
---<br>
<br>
That is, remove the #ifndef, first #define, #else, and #endif from that<br>
file so it just says 'uniqify_rc(f,r)(f)'.<br>
<br>
You'll be happy to know that soonish we may have a supported way to do<br>
this at runtime rather than compole time!<br>
<br>
--titus<br>
<br>
On Thu, Dec 08, 2016 at 12:51:04AM &#43;0000, Bintu, Bogdan wrote:<br>
&gt; P.S.<br>
&gt; I originally started with the indications in the link:<br>
&gt; <a href="http://lists.idyll.org/pipermail/khmer/2013-June/000394.html">http://lists.idyll.org/pipermail/khmer/2013-June/000394.html</a><br>
&gt; Another person was trying to achieve the same thing as I am and had similar issues. He managed to solve the problem<br>
&gt; <br>
&gt; ?by adding -dNO_UNIQUE_RC=1 to CXXFLAGS explicitly?<br>
&gt; in the Makefile in the root khmer folder.<br>
&gt; I did not figure out where exactly to add this. I also do not know whether this person?s reported bug was fixed in later versions.<br>
&gt; Regards,<br>
&gt; Bogdan<br>
&gt; <br>
&gt; <br>
&gt; From: Bintu, Bogdan&lt;<a href="mailto:bbintu@fas.harvard.edu">mailto:bbintu@fas.harvard.edu</a>&gt;<br>
&gt; Sent: Wednesday, December 7, 2016 4:21 PM<br>
&gt; To: C. Titus Brown&lt;<a href="mailto:ctbrown@ucdavis.edu">mailto:ctbrown@ucdavis.edu</a>&gt;<br>
&gt; Cc: khmer@lists.idyll.org&lt;mailto:khmer@lists.idyll.org&gt;<br>
&gt; Subject: RE: [khmer] Unique reverse-complement<br>
&gt; <br>
&gt; <br>
&gt; Dear Titus,<br>
&gt; <br>
&gt; Thanks for the prompt reply.<br>
&gt; <br>
&gt; Tried what you suggested but sadly it did not solve it.<br>
&gt; <br>
&gt; Any other suggestion?<br>
&gt; <br>
&gt; Regards,<br>
&gt; <br>
&gt; Bogdan<br>
&gt; <br>
&gt; <br>
&gt; <br>
&gt; From: C. Titus Brown&lt;<a href="mailto:ctbrown@ucdavis.edu">mailto:ctbrown@ucdavis.edu</a>&gt;<br>
&gt; Sent: Wednesday, December 7, 2016 3:32 PM<br>
&gt; To: Bintu, Bogdan&lt;<a href="mailto:bbintu@fas.harvard.edu">mailto:bbintu@fas.harvard.edu</a>&gt;<br>
&gt; Cc: khmer@lists.idyll.org&lt;mailto:khmer@lists.idyll.org&gt;<br>
&gt; Subject: Re: [khmer] Unique reverse-complement<br>
&gt; <br>
&gt; <br>
&gt; <br>
&gt; On Wed, Dec 07, 2016 at 08:18:31PM &#43;0000, Bintu, Bogdan wrote:<br>
&gt; &gt; Dear Dr. Brown,<br>
&gt; &gt;<br>
&gt; &gt; I am a graduate student using your khmer package.<br>
&gt; &gt; I am trying to construct a khmer.Countgraph which is not degenerate between a sequence and its reverse complement.<br>
&gt; &gt; More explicitly, in python when running:<br>
&gt; &gt;<br>
&gt; &gt; import Khmer<br>
&gt; &gt; ht = khmer.Countgraph(17,10,1)<br>
&gt; &gt; ht.consume('GGCTTGCTCCAGCCATG')<br>
&gt; &gt; ht.get('CATGGCTGGAGCAAGCC')<br>
&gt; &gt;<br>
&gt; &gt; I would like the last line to return 0.<br>
&gt; &gt;<br>
&gt; &gt; As suggested in a different thread I tired modifying NO_UNIQUE_RC=0 to NO_UNIQUE_RC=1 in lib/Makefile and then run python setup.py install.<br>
&gt; &gt; But this did not solve my issue.<br>
&gt; &gt;<br>
&gt; &gt; Any help would be appreciated.<br>
&gt; <br>
&gt; Hi Bogdan,<br>
&gt; <br>
&gt; thanks for the email!<br>
&gt; <br>
&gt; Can you try doing:<br>
&gt; <br>
&gt; make clean<br>
&gt; python setup.py install<br>
&gt; <br>
&gt; after the modification?&nbsp; That should work.<br>
&gt; <br>
&gt; thanks,<br>
&gt; --titus<br>
&gt; --<br>
&gt; C. Titus Brown, ctbrown@ucdavis.edu<br>
<br>
-- <br>
C. Titus Brown, ctbrown@ucdavis.edu<br>
</div>
</span></font>
</body>
</html>