PollyTikhonova/ImGQfinder

No file generated in the output folder

Closed this issue · 4 comments

I follow the steps given on the readme file. The program run perfectly but no file is generated in the output folder. I tried with the test file which you provide on the Github repo. also facing the same issues.

The ImGQfinder will generate quadruplets, quadruplexes, groups and ranges files.
Loading .\test\chr1_chunk1.fasta
This fasta file contains 1 sequences.
Processing chr1_chunk1:
Quadrupleting: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 199996/199996 [00:00<00:00, 320467.19it/s]
Qadruplexing: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3310/3310 [00:00<00:00, 186343.45it/s]
Grouping: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 8/8 [00:00<?, ?it/s]
Converting to ranges: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3/3 [00:00<?, ?it/s]
Postprocessing quadruplets: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3310/3310 [00:00<00:00, 3354227.17it/s]
Postprocessing quadruplexes: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 9/9 [00:00<?, ?it/s]
Postprocessing groups: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3/3 [00:00<?, ?it/s]
Saving tables:   0%|                                                                                                                                                                                                  | 0/1 [00:00<?, ?it/s]C:\Github\G4orce\algo\ImGQfinder\imgqfinder.py:583: VisibleDeprecationWarning: Creating an ndarray from ragged nested sequences (which is a list-or-tuple of lists-or-tuples-or ndarrays with different lengths or shapes) is deprecated. If you meant to do this, you must specify 'dtype=object' when creating the ndarray.
  data = np.array([(quadruplets_toprint, columns_set1, fasta_id, 'quadruplets.csv'),
Saving tables: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:00<00:00,  1.37it/s]
Finished
The ImGQfinder will generate quadruplets, quadruplexes, groups and ranges files.
Loading chr1.fasta
This fasta file contains 1 sequences.
Processing chr1_chunk1:
Quadrupleting: 100%|████████████████████████████████████████████████████████| 199996/199996 [00:00<00:00, 331781.18it/s]
Qadruplexing: 100%|█████████████████████████████████████████████████████████████| 3310/3310 [00:00<00:00, 280632.01it/s]
Grouping: 100%|███████████████████████████████████████████████████████████████████████| 8/8 [00:00<00:00, 172960.99it/s]
Converting to ranges: 100%|███████████████████████████████████████████████████████████| 3/3 [00:00<00:00, 149796.57it/s]
Postprocessing quadruplets: 100%|██████████████████████████████████████████████| 3310/3310 [00:00<00:00, 2270714.14it/s]
Postprocessing quadruplexes: 100%|█████████████████████████████████████████████████████| 9/9 [00:00<00:00, 48333.85it/s]
Postprocessing groups: 100%|███████████████████████████████████████████████████████████| 3/3 [00:00<00:00, 24720.85it/s]
Saving tables:   0%|                                                                              | 0/1 [00:00<?, ?it/s]imgqfinder.py:586: VisibleDeprecationWarning: Creating an ndarray from ragged nested sequences (which is a list-or-tuple of lists-or-tuples-or ndarrays with different lengths or shapes) is deprecated. If you meant to do this, you must specify 'dtype=object' when creating the ndarray.
  (ranges, ['Fasta ID', 'Start', 'End'], fasta_id, 'ranges.bed')])[output_type]
Saving tables:   0%|                                                                              | 0/1 [00:00<?, ?it/s]
multiprocessing.pool.RemoteTraceback:
"""
Traceback (most recent call last):
  File "/home/recervictory/anaconda3/envs/imgqfinder_env/lib/python3.7/multiprocessing/pool.py", line 121, in worker
    result = (True, func(*args, **kwds))
  File "/home/recervictory/anaconda3/envs/imgqfinder_env/lib/python3.7/multiprocessing/pool.py", line 44, in mapstar
    return list(map(*args))
  File "imgqfinder.py", line 442, in save_tables_wrapper
    return self.save_tables(*args)
  File "imgqfinder.py", line 420, in save_tables
    with open('{}/{}_{}'.format(self.output_path, fasta_id, which_table), 'w') as f:
PermissionError: [Errno 13] Permission denied: '/chr1_chunk1_quadruplets.csv'
"""

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "imgqfinder.py", line 646, in <module>
    main()
  File "imgqfinder.py", line 643, in main
    finder.run(print_sequences= not args.no_sequences, output_type = output_type)
  File "imgqfinder.py", line 587, in run
    pool.map(self.save_tables_wrapper, data)
  File "/home/recervictory/anaconda3/envs/imgqfinder_env/lib/python3.7/multiprocessing/pool.py", line 268, in map
    return self._map_async(func, iterable, mapstar, chunksize).get()
  File "/home/recervictory/anaconda3/envs/imgqfinder_env/lib/python3.7/multiprocessing/pool.py", line 657, in get
    raise self._value
PermissionError: [Errno 13] Permission denied: '/chr1_chunk1_quadruplets.csv'

Hello, According to your second comment you try to save file in a root folder - where the permission is denied
For the first comment, do you mind to send a code string which generated this output?

Thanks, @PollyTikhonova, I find typo in the code, I am writing
python imgqfinder.py -i data.fasta -o test
The correct code format should be
python imgqfinder.py -i data.fasta -o test\

I am missing \ on the end of the line that creates all the problems, please change the readme file, so that others don't face the same issue.

Really Thanks.

oh, thank you for finding this!