Generate new configuration file with simplified format
(self, act_parallel, row_block_size, col_block_size, parallel_size)
| 35 | shutil.copy2(self.backup_path, self.config_path) |
| 36 | |
| 37 | def generate_config(self, act_parallel, row_block_size, col_block_size, parallel_size): |
| 38 | """Generate new configuration file with simplified format""" |
| 39 | content = "" |
| 40 | |
| 41 | # Simplified configuration format |
| 42 | if act_parallel: |
| 43 | content += "#define ACT_PARALLEL\n" |
| 44 | |
| 45 | content += f"#define ROW_BLOCK_SIZE {row_block_size}\n" |
| 46 | content += f"#define COL_BLOCK_SIZE {col_block_size}\n" |
| 47 | content += f"#define PARALLEL_SIZE {parallel_size}\n" |
| 48 | |
| 49 | with open(self.config_path, 'w') as f: |
| 50 | f.write(content) |
| 51 | |
| 52 | def rebuild_project(self): |
| 53 | """Rebuild project""" |