{"action":"created","issue":{"url":"https://api.github.com/repos/enasequence/cramtools/issues/43","labels_url":"https://api.github.com/repos/enasequence/cramtools/issues/43/labels{/name}","comments_url":"https://api.github.com/repos/enasequence/cramtools/issues/43/comments","events_url":"https://api.github.com/repos/enasequence/cramtools/issues/43/events","html_url":"https://github.com/enasequence/cramtools/issues/43","id":105914008,"number":43,"title":"best approach for lossless compression","user":{"login":"lonestar21","id":9285915,"avatar_url":"https://avatars.githubusercontent.com/u/9285915?v=3","gravatar_id":"","url":"https://api.github.com/users/lonestar21","html_url":"https://github.com/lonestar21","followers_url":"https://api.github.com/users/lonestar21/followers","following_url":"https://api.github.com/users/lonestar21/following{/other_user}","gists_url":"https://api.github.com/users/lonestar21/gists{/gist_id}","starred_url":"https://api.github.com/users/lonestar21/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lonestar21/subscriptions","organizations_url":"https://api.github.com/users/lonestar21/orgs","repos_url":"https://api.github.com/users/lonestar21/repos","events_url":"https://api.github.com/users/lonestar21/events{/privacy}","received_events_url":"https://api.github.com/users/lonestar21/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2015-09-10T22:50:51Z","updated_at":"2015-09-11T15:11:06Z","closed_at":null,"body":"Hi,\r\nI have been testing cramtools (2.1 and 3.0) with bams created by a number of versions of BWA.    I have yet to be able to completely reproduce my original bam after converting to CRAM and back to BAM.\r\n\r\nIt seems that when I have either NM or MD tags in the original bam, I can't seem to get them stored in the CRAM and instead I need to recreate them during decompression.    If I don't ask to have those two fields recalculated during decompression, they don't show up for any reads, but when I use the \"--calculate-md-tag\" and \" --calculate-nm-tag\" switches  I get the flags for all reads.   \r\n\r\nWhat I want is to get the NM and MD flags for only the reads that had those flags in the original bam.  is there a way to do this?\r\n"},"comment":{"url":"https://api.github.com/repos/enasequence/cramtools/issues/comments/139571238","html_url":"https://github.com/enasequence/cramtools/issues/43#issuecomment-139571238","issue_url":"https://api.github.com/repos/enasequence/cramtools/issues/43","id":139571238,"user":{"login":"lonestar21","id":9285915,"avatar_url":"https://avatars.githubusercontent.com/u/9285915?v=3","gravatar_id":"","url":"https://api.github.com/users/lonestar21","html_url":"https://github.com/lonestar21","followers_url":"https://api.github.com/users/lonestar21/followers","following_url":"https://api.github.com/users/lonestar21/following{/other_user}","gists_url":"https://api.github.com/users/lonestar21/gists{/gist_id}","starred_url":"https://api.github.com/users/lonestar21/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lonestar21/subscriptions","organizations_url":"https://api.github.com/users/lonestar21/orgs","repos_url":"https://api.github.com/users/lonestar21/repos","events_url":"https://api.github.com/users/lonestar21/events{/privacy}","received_events_url":"https://api.github.com/users/lonestar21/received_events","type":"User","site_admin":false},"created_at":"2015-09-11T15:11:06Z","updated_at":"2015-09-11T15:11:06Z","body":"Hi folks,\r\nThanks for the quick responses.     The reason I'm looking in to this is that we are looking in to using cram for long term storage, and the validation/paperwork/testing becomes exponentially more involved when we can't regenerate an exact copy of the bam that we started with.    We'll have to test every tool in our pipeline (re-aligners, de novo assemblers, variant callers, etc.) and assess the amount of variation we see on the output due to tags being added or removed.  Even if we we don't expect anything to change it is actually a few months of work to rigorously prove results are acceptable.   On the other hand, if the BAMs are the same, this is just a few hours of work.\r\n\r\nthanks,\r\nRichard\r\n"}}