mirror of
				https://gitlab.science.ru.nl/mthesis-edeboone/m-thesis-introduction.git
				synced 2025-10-31 03:46:44 +01:00 
			
		
		
		
	ZH: matrix: setup softlink for clockfiles if possible
This commit is contained in:
		
							parent
							
								
									a58567728d
								
							
						
					
					
						commit
						bc712b5dbb
					
				
					 1 changed files with 8 additions and 1 deletions
				
			
		| 
						 | 
				
			
			@ -17,10 +17,17 @@ for options in product(baselines, clock_devs, noise_sigmas, trace_lengths):
 | 
			
		|||
 | 
			
		||||
    # Make directory
 | 
			
		||||
    if path.exists(dirname):
 | 
			
		||||
        print(f"{dirname} already exists! continuing..")
 | 
			
		||||
        print(f"{dirname} already exists! continuing anyway..")
 | 
			
		||||
 | 
			
		||||
    os.makedirs(dirname, exist_ok=True)
 | 
			
		||||
 | 
			
		||||
    # Soft link clock file if available
 | 
			
		||||
    if True:
 | 
			
		||||
        os.makedirs(path.join(dirname, 'data'), exist_ok=True)
 | 
			
		||||
 | 
			
		||||
        if not path.isfile(path.join(dirname, 'data/clocks.csv')):
 | 
			
		||||
            os.symlink(f'../../c{clk_dev}_clocks.csv', path.join(dirname, 'data/clocks.csv'))
 | 
			
		||||
 | 
			
		||||
    # Setup config.mk
 | 
			
		||||
    with open(path.join(dirname, 'env.sh'), 'w') as fp:
 | 
			
		||||
        template = f"""
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue