kssdtree 1.1.3__tar.gz → 1.1.4__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {kssdtree-1.1.3/kssdtree.egg-info → kssdtree-1.1.4}/PKG-INFO +1 -1
- {kssdtree-1.1.3 → kssdtree-1.1.4/kssdtree.egg-info}/PKG-INFO +1 -1
- {kssdtree-1.1.3 → kssdtree-1.1.4}/kssdtree.py +28 -28
- {kssdtree-1.1.3 → kssdtree-1.1.4}/setup.py +1 -1
- {kssdtree-1.1.3 → kssdtree-1.1.4}/MANIFEST.in +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/README.md +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/align.c +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/buildtree.c +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/bytescale.c +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/cluster.c +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/co2mco.c +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/command_composite.c +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/command_dist.c +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/command_dist_wrapper.c +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/command_set.c +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/command_shuffle.c +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/distancemat.c +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/dnj.c +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/dnjheaders/bytescale.h +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/dnjheaders/dnj.h +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/dnjheaders/filebuff.h +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/dnjheaders/hclust.h +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/dnjheaders/matrix.h +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/dnjheaders/mman.h +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/dnjheaders/nj.h +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/dnjheaders/nwck.h +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/dnjheaders/pherror.h +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/dnjheaders/phy.h +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/dnjheaders/qseqs.h +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/dnjheaders/str.h +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/dnjheaders/threader.h +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/dnjheaders/tmp.h +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/dnjheaders/vector.h +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/filebuff.c +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/global_basic.c +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/hclust.c +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/iseq2comem.c +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/kssdheaders/co2mco.h +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/kssdheaders/command_composite.h +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/kssdheaders/command_dist.h +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/kssdheaders/command_dist_wrapper.h +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/kssdheaders/command_set.h +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/kssdheaders/command_shuffle.h +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/kssdheaders/global_basic.h +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/kssdheaders/iseq2comem.h +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/kssdheaders/mman.h +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/kssdheaders/mytime.h +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/kssdtree.egg-info/SOURCES.txt +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/kssdtree.egg-info/dependency_links.txt +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/kssdtree.egg-info/not-zip-safe +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/kssdtree.egg-info/requires.txt +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/kssdtree.egg-info/top_level.txt +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/matrix.c +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/mman.c +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/mytime.c +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/nj.c +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/njheaders/align.h +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/njheaders/buildtree.h +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/njheaders/cluster.h +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/njheaders/distancemat.h +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/njheaders/sequence.h +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/njheaders/tree.h +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/njheaders/util.h +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/nwck.c +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/pherror.c +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/phy.c +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/pydnj.c +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/pykssd.c +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/pynj.c +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/qseqs.c +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/sequence.c +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/setup.cfg +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/str.c +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/tmp.c +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/toolutils.py +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/tree.c +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/util.c +0 -0
- {kssdtree-1.1.3 → kssdtree-1.1.4}/vector.c +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 1.1
|
|
2
2
|
Name: kssdtree
|
|
3
|
-
Version: 1.1.
|
|
3
|
+
Version: 1.1.4
|
|
4
4
|
Summary: Kssdtree is a versatile Python package for phylogenetic analysis. It also provides one-stop tree construction and visualization. It can handle DNA sequences of both fasta or fastq format, whether gzipped or not.
|
|
5
5
|
Home-page: https://github.com/yhlink/kssdtree
|
|
6
6
|
Author: Hang Yang
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 1.1
|
|
2
2
|
Name: kssdtree
|
|
3
|
-
Version: 1.1.
|
|
3
|
+
Version: 1.1.4
|
|
4
4
|
Summary: Kssdtree is a versatile Python package for phylogenetic analysis. It also provides one-stop tree construction and visualization. It can handle DNA sequences of both fasta or fastq format, whether gzipped or not.
|
|
5
5
|
Home-page: https://github.com/yhlink/kssdtree
|
|
6
6
|
Author: Hang Yang
|
|
@@ -13,15 +13,15 @@ def shuffle(k=None, s=None, l=None, o=None):
|
|
|
13
13
|
kssd.write_dim_shuffle_file(k, s, l, o)
|
|
14
14
|
|
|
15
15
|
|
|
16
|
-
def sketch(shuf_file=None,
|
|
17
|
-
if shuf_file is not None and
|
|
18
|
-
if not os.path.exists(
|
|
19
|
-
print('No such file or directory: ',
|
|
16
|
+
def sketch(shuf_file=None, genome_files=None, output=None, set_opt=None):
|
|
17
|
+
if shuf_file is not None and genome_files is not None and output is not None:
|
|
18
|
+
if not os.path.exists(genome_files):
|
|
19
|
+
print('No such file or directory: ', genome_files)
|
|
20
20
|
return False
|
|
21
21
|
if set_opt is None:
|
|
22
22
|
set_opt = False
|
|
23
|
-
if not toolutils.allowed_file(
|
|
24
|
-
for filename in os.listdir(
|
|
23
|
+
if not toolutils.allowed_file(genome_files):
|
|
24
|
+
for filename in os.listdir(genome_files):
|
|
25
25
|
if not toolutils.allowed_file(filename):
|
|
26
26
|
print('Genome format error for file:', filename)
|
|
27
27
|
return False
|
|
@@ -61,9 +61,9 @@ def sketch(shuf_file=None, genomes_file=None, output=None, set_opt=None):
|
|
|
61
61
|
print('Sketching...')
|
|
62
62
|
start = time.time()
|
|
63
63
|
if set_opt:
|
|
64
|
-
kssd.dist_dispatch(shuf_file,
|
|
64
|
+
kssd.dist_dispatch(shuf_file, genome_files, output, 1, 0, 0)
|
|
65
65
|
else:
|
|
66
|
-
kssd.dist_dispatch(shuf_file,
|
|
66
|
+
kssd.dist_dispatch(shuf_file, genome_files, output, 0, 0, 0)
|
|
67
67
|
end = time.time()
|
|
68
68
|
print('Sketch spend time:%.2fs' % (end - start))
|
|
69
69
|
print('Sketch finished!')
|
|
@@ -209,18 +209,18 @@ def union(ref_sketch=None, output=None):
|
|
|
209
209
|
return False
|
|
210
210
|
|
|
211
211
|
|
|
212
|
-
def subtract(ref_sketch=None,
|
|
213
|
-
if ref_sketch is not None and
|
|
212
|
+
def subtract(ref_sketch=None, genome_sketch=None, output=None, flag=None):
|
|
213
|
+
if ref_sketch is not None and genome_sketch is not None and output is not None:
|
|
214
214
|
if not os.path.exists(ref_sketch):
|
|
215
215
|
print('No such file or directory: ', ref_sketch)
|
|
216
216
|
return False
|
|
217
|
-
if not os.path.exists(
|
|
218
|
-
print('No such file or directory: ',
|
|
217
|
+
if not os.path.exists(genome_sketch):
|
|
218
|
+
print('No such file or directory: ', genome_sketch)
|
|
219
219
|
return False
|
|
220
220
|
if flag == 1:
|
|
221
221
|
print('Subtracting...')
|
|
222
222
|
start = time.time()
|
|
223
|
-
kssd.sketch_operate(ref_sketch, output,
|
|
223
|
+
kssd.sketch_operate(ref_sketch, output, genome_sketch)
|
|
224
224
|
end = time.time()
|
|
225
225
|
print('Subtract spend time:%.2fs' % (end - start))
|
|
226
226
|
print('Subtract finished!')
|
|
@@ -243,7 +243,7 @@ def subtract(ref_sketch=None, genomes_sketch=None, output=None, flag=None):
|
|
|
243
243
|
if not r:
|
|
244
244
|
print('Union error!!!')
|
|
245
245
|
return False
|
|
246
|
-
kssd.sketch_operate(temp_union_sketch, output,
|
|
246
|
+
kssd.sketch_operate(temp_union_sketch, output, genome_sketch)
|
|
247
247
|
end = time.time()
|
|
248
248
|
current_directory = os.getcwd()
|
|
249
249
|
temp_dir = os.path.join(current_directory, temp_union_sketch)
|
|
@@ -262,14 +262,14 @@ def subtract(ref_sketch=None, genomes_sketch=None, output=None, flag=None):
|
|
|
262
262
|
return False
|
|
263
263
|
|
|
264
264
|
|
|
265
|
-
def quick(shuf_file=None,
|
|
265
|
+
def quick(shuf_file=None, genome_files=None, output=None, reference=None, taxonomy=None, method='nj', mode='r', N=0):
|
|
266
266
|
if reference is None and taxonomy is None:
|
|
267
|
-
if shuf_file is not None and
|
|
267
|
+
if shuf_file is not None and genome_files is not None and output is not None:
|
|
268
268
|
timeStamp = int(time.mktime(time.localtime(time.time())))
|
|
269
|
-
temp_sketch =
|
|
269
|
+
temp_sketch = genome_files + '_sketch_' + str(timeStamp)
|
|
270
270
|
temp_phy = 'temp.phy'
|
|
271
271
|
print('Step1...')
|
|
272
|
-
s1 = sketch(shuf_file=shuf_file,
|
|
272
|
+
s1 = sketch(shuf_file=shuf_file, genome_files=genome_files, output=temp_sketch, set_opt=False)
|
|
273
273
|
if not s1:
|
|
274
274
|
return False
|
|
275
275
|
print('Step2...')
|
|
@@ -303,7 +303,7 @@ def quick(shuf_file=None, genomes_file=None, output=None, reference=None, taxono
|
|
|
303
303
|
return False
|
|
304
304
|
|
|
305
305
|
elif reference == 'gtdbr214_sketch' and taxonomy is None:
|
|
306
|
-
if shuf_file is not None and
|
|
306
|
+
if shuf_file is not None and genome_files is not None and output is not None:
|
|
307
307
|
if not toolutils.is_positive_integer(N):
|
|
308
308
|
print("N must >0 !!!")
|
|
309
309
|
return False
|
|
@@ -311,8 +311,8 @@ def quick(shuf_file=None, genomes_file=None, output=None, reference=None, taxono
|
|
|
311
311
|
print("shuffle file must be set to 'L3K9.shuf'")
|
|
312
312
|
return False
|
|
313
313
|
timeStamp = int(time.mktime(time.localtime(time.time())))
|
|
314
|
-
qry_sketch =
|
|
315
|
-
s1 = sketch(shuf_file=shuf_file,
|
|
314
|
+
qry_sketch = genome_files + '_sketch_' + str(timeStamp)
|
|
315
|
+
s1 = sketch(shuf_file=shuf_file, genome_files=genome_files, output=qry_sketch, set_opt=True)
|
|
316
316
|
if not s1:
|
|
317
317
|
return False
|
|
318
318
|
s2 = retrieve(ref_sketch=reference, qry_sketch=qry_sketch, output=output, N=N, method=method)
|
|
@@ -328,11 +328,11 @@ def quick(shuf_file=None, genomes_file=None, output=None, reference=None, taxono
|
|
|
328
328
|
print('Args error!!!')
|
|
329
329
|
return False
|
|
330
330
|
else:
|
|
331
|
-
if shuf_file is not None and
|
|
332
|
-
if shuf_file is not None and
|
|
331
|
+
if shuf_file is not None and genome_files is not None and output is not None and method in ['nj', 'dnj']:
|
|
332
|
+
if shuf_file is not None and genome_files is not None and output is not None and method in ['nj', 'dnj']:
|
|
333
333
|
timeStamp = int(time.mktime(time.localtime(time.time())))
|
|
334
334
|
temp_reference_sketch = 'ref_sketch_' + str(timeStamp)
|
|
335
|
-
temp_genomes_sketch =
|
|
335
|
+
temp_genomes_sketch = genome_files + '_sketch_' + str(timeStamp)
|
|
336
336
|
if not toolutils.allowed_file(reference):
|
|
337
337
|
cur_path = os.getcwd()
|
|
338
338
|
ref_path = os.path.join(cur_path, reference)
|
|
@@ -343,20 +343,20 @@ def quick(shuf_file=None, genomes_file=None, output=None, reference=None, taxono
|
|
|
343
343
|
temp_union_sketch = 'ref_union_sketch_' + str(timeStamp)
|
|
344
344
|
else:
|
|
345
345
|
temp_union_sketch = temp_reference_sketch
|
|
346
|
-
temp_subtract_sketch =
|
|
346
|
+
temp_subtract_sketch = genome_files + '_subtract_sketch_' + str(timeStamp)
|
|
347
347
|
temp_phy = 'temp.phy'
|
|
348
348
|
print('Step1...')
|
|
349
|
-
s1 = sketch(shuf_file=shuf_file,
|
|
349
|
+
s1 = sketch(shuf_file=shuf_file, genome_files=reference, output=temp_reference_sketch, set_opt=True)
|
|
350
350
|
if not s1:
|
|
351
351
|
return False
|
|
352
|
-
s2 = sketch(shuf_file=shuf_file,
|
|
352
|
+
s2 = sketch(shuf_file=shuf_file, genome_files=genome_files, output=temp_genomes_sketch, set_opt=True)
|
|
353
353
|
if not s2:
|
|
354
354
|
return False
|
|
355
355
|
print('Step2...')
|
|
356
356
|
s3 = union(ref_sketch=temp_reference_sketch, output=temp_union_sketch)
|
|
357
357
|
if not s3:
|
|
358
358
|
return False
|
|
359
|
-
s4 = subtract(ref_sketch=temp_union_sketch,
|
|
359
|
+
s4 = subtract(ref_sketch=temp_union_sketch, genome_sketch=temp_genomes_sketch,
|
|
360
360
|
output=temp_subtract_sketch, flag=1)
|
|
361
361
|
if not s4:
|
|
362
362
|
return False
|
|
@@ -93,7 +93,7 @@ require_pakages = [
|
|
|
93
93
|
|
|
94
94
|
setup(
|
|
95
95
|
name='kssdtree',
|
|
96
|
-
version='1.1.
|
|
96
|
+
version='1.1.4',
|
|
97
97
|
author='Hang Yang',
|
|
98
98
|
author_email='yhlink1207@gmail.com',
|
|
99
99
|
description="Kssdtree is a versatile Python package for phylogenetic analysis. It also provides one-stop tree construction and visualization. It can handle DNA sequences of both fasta or fastq format, whether gzipped or not. ",
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|