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

SQMtools issue with running sqm2tables.py #505

Closed
mefeeney opened this issue Jun 15, 2022 · 3 comments
Closed

SQMtools issue with running sqm2tables.py #505

mefeeney opened this issue Jun 15, 2022 · 3 comments

Comments

@mefeeney
Copy link

Having issues working with my data in r using SQMtools. Seen other users with similar issues but the fixes associated with #416 do not seem to be helping and I'm not sure what I'm doing wrong.
I ran squeezemeta in a hpc/computing cluster. Downloaded the resulting project folder locally to a windows computer.
Both cluster and local windows squeezemeta installs are version 1.5.1. and are the same version as far as I am aware.
I have R (v 4.1.3) and R studio (2021.09.1 Build 372) currently installed.
I installed SQMtools in R with the following:
install.packages("reshape2")
install.packages("pathviewr")
install.packages("data.table")
install.packages("BiocManager")
BiocManager::install("pathview")
install.packages("H:/Cluster_backup/SqueezeMeta/lib/SQMtools", repos = NULL, type = "source")
library(SQMtools)
library(reshape2)
library(data.table)
library(BiocManager)
library(pathview)

  • Note I installed pathview with BiocManager because install.packages("pathview") gives an error along the lines of 'pathview is not available for this version of R). Followed instructions from here.

SQMtools will load, and I can run 'loadSQMlite' on the outputs I generated from sqm2tables.py however I cannot use 'subsetTax' on the resulting object because The first argument must be a SQM object.

I cannot run loadSQM when I give it the path to my squeezemeta analysis folder. (project.large=loadSQM("H:/Cluster_backup/water500test3"))
I get the following error:
Error in loadSQM("H:/Cluster_backup/water500test3") :
An error occurred while running sqm2tables.py
In addition: Warning message:
In sprintf("%s/results/tables/%s.superkingdom.%s.abund.tsv", project_path, :
one argument not used by format '%s/results/tables/%s.superkingdom.%s.abund.tsv'

I tried the solution in #416 , changing the following:
$installpath = "/home/zeiss/anaconda3/envs/SqueezeMeta/SqueezeMeta";
#$databasepath = "/mnt/h/Cluster_backup/SqueezeMeta/makedb/db";
$databasepath = "/mnt/h/Cluster_backup/SqueezeMeta/makedb/db";

I added $mappingstat = "$resultpath/10.$projectname.mappingstat"; to line 55,

I tried re-running step 9 perl script for my project

I still get the error?

@fpusan
Copy link
Collaborator

fpusan commented Jun 16, 2022

Hi!
Did you follow
https://github.com/jtamames/SqueezeMeta/wiki/Using-SQMtools-in-a-Windows-environment
?
You need to run sqm2tables.py manually in the Linux environment before migrating the data to Windows.
Try:
sqm2tables.py /path/to/project /path/to/project/results/tables
And then move the project to your Windows computer (you don't need all the files, the needed files are listed in the wiki article I linked).
Let me know if this works for you.

@mefeeney
Copy link
Author

Hello,

Thank you for pointing this out, the issue was I put the wrong output path for sqm2tables.py when I ran it on the cluster.
I ran sqm2tables.py with /path/to/project/results/tables, and running SQMtools locally worked fine.

@fpusan
Copy link
Collaborator

fpusan commented Jun 16, 2022

Glad to hear it works!

@fpusan fpusan closed this as completed Jun 16, 2022
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