11import json
22
3+ import os
34import dask .array as da
45import pandas as pd
56import xarray
@@ -59,7 +60,7 @@ def sample_metadata(self):
5960 One row per sample.
6061 """
6162 if self ._cache_sample_metadata is None :
62- path = f" { self ._path } / { self .CONF [' metadata_path' ] } "
63+ path = os . path . join ( self ._path , self .CONF [" metadata_path" ])
6364 with self ._fs .open (path ) as f :
6465 self ._cache_sample_metadata = pd .read_csv (f , sep = "\t " , na_values = "" )
6566 return self ._cache_sample_metadata
@@ -74,7 +75,7 @@ def _open_variant_calls_zarr(self):
7475
7576 """
7677 if self ._cache_variant_calls_zarr is None :
77- path = f" { self ._path } / { self .CONF [' variant_calls_zarr_path' ] } "
78+ path = os . path . join ( self ._path , self .CONF [" variant_calls_zarr_path" ])
7879 store = _init_zarr_store (fs = self ._fs , path = path )
7980 self ._cache_variant_calls_zarr = zarr .open_consolidated (store = store )
8081 return self ._cache_variant_calls_zarr
@@ -204,7 +205,7 @@ def open_genome(self):
204205
205206 """
206207 if self ._cache_genome is None :
207- path = f" { self ._path } / { self .CONF [' reference_path' ] } "
208+ path = os . path . join ( self ._path , self .CONF [" reference_path" ])
208209 store = _init_zarr_store (fs = self ._fs , path = path )
209210 self ._cache_genome = zarr .open_consolidated (store = store )
210211 return self ._cache_genome
@@ -316,7 +317,7 @@ def genome_features(self, attributes=("ID", "Parent", "Name")):
316317 try :
317318 df = self ._cache_genome_features [attributes ]
318319 except KeyError :
319- path = f" { self ._path } / { self .CONF [' annotations_path' ] } "
320+ path = os . path . join ( self ._path , self .CONF [" annotations_path" ])
320321 with self ._fs .open (path , mode = "rb" ) as f :
321322 df = _read_gff3 (f , compression = "gzip" )
322323 if attributes is not None :
0 commit comments