@@ -404,12 +404,18 class JRODataReader(JRODataIO, ProcessingUnit): | |||||
404 | pathList = [] |
|
404 | pathList = [] | |
405 |
|
405 | |||
406 | if not walk: |
|
406 | if not walk: | |
407 | pathList.append(path) |
|
407 | #pathList.append(path) | |
|
408 | multi_path = path.split(',') | |||
|
409 | for single_path in multi_path: | |||
|
410 | pathList.append(single_path) | |||
408 |
|
411 | |||
409 | else: |
|
412 | else: | |
|
413 | #dirList = [] | |||
|
414 | multi_path = path.split(',') | |||
|
415 | for single_path in multi_path: | |||
410 | dirList = [] |
|
416 | dirList = [] | |
411 | for thisPath in os.listdir(path): |
|
417 | for thisPath in os.listdir(single_path): | |
412 | if not os.path.isdir(os.path.join(path,thisPath)): |
|
418 | if not os.path.isdir(os.path.join(single_path,thisPath)): | |
413 | continue |
|
419 | continue | |
414 | if not isDoyFolder(thisPath): |
|
420 | if not isDoyFolder(thisPath): | |
415 | continue |
|
421 | continue | |
@@ -430,7 +436,7 class JRODataReader(JRODataIO, ProcessingUnit): | |||||
430 | thisDate += datetime.timedelta(1) |
|
436 | thisDate += datetime.timedelta(1) | |
431 | continue |
|
437 | continue | |
432 | for match in matchlist: |
|
438 | for match in matchlist: | |
433 | pathList.append(os.path.join(path,match,expLabel)) |
|
439 | pathList.append(os.path.join(single_path,match,expLabel)) | |
434 |
|
440 | |||
435 | thisDate += datetime.timedelta(1) |
|
441 | thisDate += datetime.timedelta(1) | |
436 |
|
442 | |||
@@ -442,6 +448,8 class JRODataReader(JRODataIO, ProcessingUnit): | |||||
442 |
|
448 | |||
443 | filenameList = [] |
|
449 | filenameList = [] | |
444 | datetimeList = [] |
|
450 | datetimeList = [] | |
|
451 | pathDict = {} | |||
|
452 | filenameList_to_sort = [] | |||
445 |
|
453 | |||
446 | for i in range(len(pathList)): |
|
454 | for i in range(len(pathList)): | |
447 |
|
455 | |||
@@ -449,6 +457,17 class JRODataReader(JRODataIO, ProcessingUnit): | |||||
449 |
|
457 | |||
450 | fileList = glob.glob1(thisPath, "*%s" %ext) |
|
458 | fileList = glob.glob1(thisPath, "*%s" %ext) | |
451 | fileList.sort() |
|
459 | fileList.sort() | |
|
460 | pathDict.setdefault(fileList[0]) | |||
|
461 | pathDict[fileList[0]] = i | |||
|
462 | filenameList_to_sort.append(fileList[0]) | |||
|
463 | ||||
|
464 | filenameList_to_sort.sort() | |||
|
465 | ||||
|
466 | for file in filenameList_to_sort: | |||
|
467 | thisPath = pathList[pathDict[file]] | |||
|
468 | ||||
|
469 | fileList = glob.glob1(thisPath, "*%s" %ext) | |||
|
470 | fileList.sort() | |||
452 |
|
|
471 | ||
453 | for file in fileList: |
|
472 | for file in fileList: | |
454 |
|
473 |
General Comments 0
You need to be logged in to leave comments.
Login now