Open fekenzofugi opened 1 month ago
Hi, have you read and tried the commands here? https://github.com/ameraner/dsen2-cr?tab=readme-ov-file#basic-commands The Readme is currently the only documentation I can provide. I'll close the issue, please open a new specific issue if you have futher issues when running the code.
This is the error that i'm facing.
looks like the ID is not being loaded properly, maybe the path to the datasetfilelist.csv needs to be adapted? going into debug mode on your IDE where the error happens and tracing back the steps should show you the issue.
Model compiled successfully!
Getting file lists
Number of train files found: 0
Number of validation files found: 2
Number of test files found: 0
Predicting using file: model_SARplain.hdf5
Using this model: val
WARNING: Folder {} exists and content may be overwritten!
WARNING: Folder {} exists and content may be overwritten!
Initializing generator for prediction and evaluation
Generator initialized
Storing evaluation metrics at /home/nipe/dsen2-cr/output/valeval.csv
Traceback (most recent call last):
File "dsen2cr_main.py", line 179, in
Could you try to change the code here https://github.com/ameraner/dsen2-cr/blob/main/Code/tools/dataIO.py#L23 to
def get_train_val_test_filelists(listpath):
with open(listpath) as f:
reader = csv.reader(f, delimiter='\t')
filelist = list(reader)
train_filelist = []
val_filelist = []
test_filelist = []
for f in filelist:
line_entries = f[0].split(sep=", ")
if line_entries[0] == '1':
train_filelist.append(f)
if line_entries[0] == '2':
val_filelist.append(f)
if line_entries[0] == '3':
test_filelist.append(f)
return train_filelist, val_filelist, test_filelist
and see if it helps?
Thank you very much. It's working!
great :) feel free to open a Pull Request with the change if you have the chance.
I would like to know how I can run the pretrained model available in this repository. Could you provide detailed instructions on how to set up and run the model?
Thank you in advance for your help!