create fold before read
This commit is contained in:
4
SIME.py
4
SIME.py
@@ -38,7 +38,9 @@ class SIME:
|
|||||||
self.enumerate_all_sugars = enumerate_all_sugars
|
self.enumerate_all_sugars = enumerate_all_sugars
|
||||||
date_stamp = datetime.datetime.utcnow().strftime("%Y-%m-%d-%H-%M-%S")
|
date_stamp = datetime.datetime.utcnow().strftime("%Y-%m-%d-%H-%M-%S")
|
||||||
self.smile_file_name = 'LIBRARIES/'+date_stamp+'_mcrl'
|
self.smile_file_name = 'LIBRARIES/'+date_stamp+'_mcrl'
|
||||||
|
libraries_dir = 'LIBRARIES/'
|
||||||
|
if not os.path.exists(libraries_dir):
|
||||||
|
os.makedirs(libraries_dir)
|
||||||
self.info_manager = open(self.smile_file_name + '_info','a+')
|
self.info_manager = open(self.smile_file_name + '_info','a+')
|
||||||
self.info_manager.write(f'Desired Library Size (numbers only) : {self.library_size}\n')
|
self.info_manager.write(f'Desired Library Size (numbers only) : {self.library_size}\n')
|
||||||
self.info_manager.write(f'Maximum occurrence of the same structural motifs per scaffold (number only) : {self.max_repeat_motifs}\n')
|
self.info_manager.write(f'Maximum occurrence of the same structural motifs per scaffold (number only) : {self.max_repeat_motifs}\n')
|
||||||
|
|||||||
2
main.py
2
main.py
@@ -17,6 +17,8 @@ from SIME import *
|
|||||||
|
|
||||||
app = Flask(__name__)
|
app = Flask(__name__)
|
||||||
UPLOAD_FOLDER = 'uploads'
|
UPLOAD_FOLDER = 'uploads'
|
||||||
|
if not os.path.exists(UPLOAD_FOLDER):
|
||||||
|
os.makedirs(UPLOAD_FOLDER)
|
||||||
app.config['UPLOAD_FOLDER'] = UPLOAD_FOLDER
|
app.config['UPLOAD_FOLDER'] = UPLOAD_FOLDER
|
||||||
|
|
||||||
@app.route('/')
|
@app.route('/')
|
||||||
|
|||||||
Reference in New Issue
Block a user