Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Problems configuring RepeatClasifier on docker. #36

Closed
matthew-ackerman opened this issue Feb 1, 2024 · 8 comments
Closed

Problems configuring RepeatClasifier on docker. #36

matthew-ackerman opened this issue Feb 1, 2024 · 8 comments
Assignees

Comments

@matthew-ackerman
Copy link

When classifying repeats for Daphnia pulex, a Crustacean, I get >95% unknown families. I've downloaded dfam38_full.8.h5, and have dfam38_full.0.h5 in the RepeatMasker directory. I delete rmlib.config, and when I run ./tetoolsDfamUpdate.pl it seems to correctly detect the dfam library. I set the environmental variable, but when I run RepeatClassifier I still get mostly unknowns. Does RepeatClassifier use RepeatMasker's library? Is there some step I am forgetting? Thanks in advance!

@asgray asgray self-assigned this Feb 8, 2024
@asgray
Copy link
Contributor

asgray commented Feb 8, 2024

Hi, can you provide the command you used to invoke RepeatClassifier? The first thing I want to confirm is that the configured library is being mounted into the container properly.

Another possible problem is that the automatic update script only extracts the curated families from the .h5 files. It's possible that it's just not including the families that would be useful to you, and if that's the case I can help work around that.

@matthew-ackerman
Copy link
Author

matthew-ackerman commented Feb 9, 2024 via email

@matthew-ackerman
Copy link
Author

matthew-ackerman commented Feb 9, 2024 via email

@asgray
Copy link
Contributor

asgray commented Feb 9, 2024

A read-only file system could certainly be causing issues. tetoolsDfamUpdate.pl rewrites /opt/RepeatMasker/Libraries/RepeatMasker.lib, so you could confirm if that's working by checking the timestamp with ls -al.
Can you share the error message when you use the shell -w command?

@matthew-ackerman
Copy link
Author

matthew-ackerman commented Feb 21, 2024 via email

@asgray
Copy link
Contributor

asgray commented Feb 23, 2024

Thanks for confirming that the container is working. It looks like the issue is that tetoolsDfamUpdate.pl is only importing curated families into RepeatMasker.lib, and since there are no curated Daphnia families, it makes sense that you're not seeing any additional hits. To work around this, one solution is to use famdb.py to directly query the data you need.

First, I ran a few lineage queries to confirm what is in the FamDB files:

python3 famdb.py -i ./dfam38_full lineage -d daphnia
6668 Daphnia(8) [0]
├─6669 Daphnia pulex(8) [0]
└─35523 Daphnia pulicaria(8) [937]
python3 famdb.py -i ./dfam38_full lineage -d --curated daphnia
6668 Daphnia(8) [0]
├─6669 Daphnia pulex(8) [0]
└─35523 Daphnia pulicaria(8) [0]

This confirms that there are 937 uncurated families in file 8, though all are from Daphnia pulicaria. To extract them, you can use the families -f fasta_name command, and append them to your RepeatMasker.lib. The following command should generate the FASTA output from FamDB, prepend a new line to it, and concatenate it to RepeatMasker.lib.

python3 <host path to /RepeatMasker>/famdb.py -i <host path to /RepeatMasker>/Libraries/famdb families -d -f fasta_name daphnia | (echo && cat) >> <host path to /RepeatMasker>/Libraries/RepeatMasker.lib

More information regarding FamDB commands can be found here. If you need to add other FamDB files, just be aware that tetoolsDfamUpdate.pl will overwrite any changes you make to RepeatMasker.lib. You may choose to run tetoolsDfamUpdate.pl anyway, but if not you might need to edit rmlib.config by hand. If tetoolsDfamUpdate.pl is rerun, be sure to only export uncurated families from FamDB to avoid doubling up curated families in RepeatMasker.lib.

Hopefully that produces better results for you, but let me know either way.

@asgray asgray closed this as completed Mar 13, 2024
@asgray asgray pinned this issue Mar 13, 2024
@matthew-ackerman
Copy link
Author

matthew-ackerman commented Mar 13, 2024 via email

@asgray
Copy link
Contributor

asgray commented Mar 13, 2024 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants