mirror of
https://github.com/Doctorado-ML/benchmark.git
synced 2025-08-18 00:45:54 +00:00
Add --dataset to main.py
This commit is contained in:
@@ -27,13 +27,16 @@ class Diterator:
|
||||
|
||||
|
||||
class Datasets:
|
||||
def __init__(self):
|
||||
try:
|
||||
with open(os.path.join(Folders.data, Files.index)) as f:
|
||||
self.data_sets = f.read().splitlines()
|
||||
except FileNotFoundError:
|
||||
with open(os.path.join("..", Folders.data, Files.index)) as f:
|
||||
self.data_sets = f.read().splitlines()
|
||||
def __init__(self, dataset=None):
|
||||
if dataset is None:
|
||||
try:
|
||||
with open(os.path.join(Folders.data, Files.index)) as f:
|
||||
self.data_sets = f.read().splitlines()
|
||||
except FileNotFoundError:
|
||||
with open(os.path.join("..", Folders.data, Files.index)) as f:
|
||||
self.data_sets = f.read().splitlines()
|
||||
else:
|
||||
self.data_sets = [dataset]
|
||||
|
||||
def load(self, name):
|
||||
try:
|
||||
|
Reference in New Issue
Block a user