defines.h 2.03 KB
Newer Older
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
/*

OCLADock, an OpenCL implementation of AutoDock 4.2 running a Lamarckian Genetic Algorithm
Copyright (C) 2017 TU Darmstadt, Embedded Systems and Applications Group, Germany. All rights reserved.

AutoDock is a Trade Mark of the Scripps Research Institute.

This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License
as published by the Free Software Foundation; either version 2
of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.

*/


Leonardo Solis's avatar
Leonardo Solis committed
25
26
27
28
29
30
31
32
33
34
35
#ifndef DEFINES_H_
#define DEFINES_H_

#if defined (N16WI)
	#define NUM_OF_THREADS_PER_BLOCK 16
#elif defined (N32WI)
	#define NUM_OF_THREADS_PER_BLOCK 32
#elif defined (N64WI)
	#define NUM_OF_THREADS_PER_BLOCK 64
#elif defined (N128WI)
	#define NUM_OF_THREADS_PER_BLOCK 128
lvs's avatar
lvs committed
36
37
#elif defined (N256WI)
	#define NUM_OF_THREADS_PER_BLOCK 256
Leonardo Solis's avatar
Leonardo Solis committed
38
39
40
41
#else
	#define NUM_OF_THREADS_PER_BLOCK 64
#endif

42
#define MAX_NUM_OF_ATOMS 	100 // TODO: optimize local arrays in gradient calc to increase this constant up to 256
43
44
45
46
47
48
#define MAX_NUM_OF_ATYPES 	14
#define MAX_NUM_OF_ROTBONDS 	32
#define MAX_INTRAE_CONTRIBUTORS (MAX_NUM_OF_ATOMS * MAX_NUM_OF_ATOMS)
#define MAX_NUM_OF_ROTATIONS 	(MAX_NUM_OF_ATOMS * MAX_NUM_OF_ROTBONDS)
#define MAX_POPSIZE 		2048
#define MAX_NUM_OF_RUNS 	1000
Leonardo Solis's avatar
Leonardo Solis committed
49
50
51
52
53

// Must be bigger than MAX_NUM_OF_ROTBONDS+6
#define GENOTYPE_LENGTH_IN_GLOBMEM 64
#define ACTUAL_GENOTYPE_LENGTH	(MAX_NUM_OF_ROTBONDS+6)

54
55
#define LS_EXP_FACTOR 		2.0f
#define LS_CONT_FACTOR 		0.5f
Leonardo Solis's avatar
Leonardo Solis committed
56
57
58
59

// Improvements over Pechan's implementation
#define MAPPED_COPY

60
61
62
63
64




// TODO: convert this into a program arg
Leonardo Solis's avatar
Leonardo Solis committed
65
#define GRADIENT_ENABLED
66

67
68
69
70




Leonardo Solis's avatar
Leonardo Solis committed
71
#endif /* DEFINES_H_ */