-
Notifications
You must be signed in to change notification settings - Fork 17
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
RuntimeError: runtime_error: arg <= 0 #71
Comments
Hi, I have been getting the exactly same error message as this. Have you had any luck trouble-shooting this? Your experience and help will be much appreciated! |
Has anyone fixed this successfully yet? I'm having the same issue |
RuntimeError arg <=0I encountered this issue when running the fit1 process (with the script bombing quite early (line 500ish).
There may be different issues with this error but I found a solution by performing some harmonisation of my reference data to the sumstats I was using. My initial (errored) approach was to create reference *.ld and *.snps from b37-1000g-eur binaries contained ~20M+ SNPs. My aim was to create a reusable set of reference files for use across multiple data. My "FAILED" analysis came when applying these to sumstats which contained only ~4M+ SNPs. My thoughts was that the My local pipeline initially included removal of ambiguous SNPs (gt = W|S), harmonising rsid, removal of regions of high-LD (from b37 from https://genome.sph.umich.edu/wiki/Regions_of_high_linkage_disequilibrium_(LD)). This was applied to the sumstats but not binaries used to create the reference files. I re-wrote my local pipeline to select overlapping SNPs, and apply the processing to both the sumstats and the binaries before creating the *.ld / *.snps files. This means that any markers in the *.snps replicates will be in the sumstats file - removing the 15M+ non-overlapping SNPs (and hopefully we have SNPS present in each block). ...and now the script works :) |
Does anyone know why this error occurs and how to fix it?
Traceback (most recent call last):
File "/home/lilab/software/mixer-master/precimed/mixer.py", line 23, in
args.func(args)
File "/home/lilab/software/mixer-master/precimed/mixer/cli.py", line 647, in execute_fit1_or_test1_parser
results = init_results_struct(libbgmg, args)
File "/home/lilab/software/mixer-master/precimed/mixer/cli.py", line 639, in init_results_struct
results['options']['sum_weights'] = float(np.sum(libbgmg.weights))
File "/home/lilab/software/mixer-master/precimed/mixer/libbgmg.py", line 168, in weights
return self._get_vec_impl(self.cdll.bgmg_retrieve_weights, np.float32, self.num_tag, trait=None)
File "/home/lilab/software/mixer-master/precimed/mixer/libbgmg.py", line 410, in _get_vec_impl
self._check_error(func(*args))
File "/home/lilab/software/mixer-master/precimed/mixer/libbgmg.py", line 418, in _check_error
raise RuntimeError(self.get_last_error())
RuntimeError: runtime_error: arg <= 0
The text was updated successfully, but these errors were encountered: