Random Generator¶
RandomGenerator
¶
Bases: Generator
Random number generator.
Source code in xopt/generators/random.py
5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 | |
__init__(**kwargs)
¶
Initialize the generator.
Source code in xopt/generator.py
149 150 151 152 153 154 | |
add_data(new_data)
¶
update dataframe with results from new evaluations.
This is intended for generators that maintain their own data.
Source code in xopt/generator.py
170 171 172 173 174 175 176 177 178 179 180 | |
generate(n_candidates)
¶
generate uniform random data points
Source code in xopt/generators/random.py
17 18 19 | |
model_dump(*args, **kwargs)
¶
overwrite model dump to remove faux class attrs
Source code in xopt/generator.py
182 183 184 185 186 187 188 189 190 | |
yaml(**kwargs)
¶
serialize first then dump to yaml string
Source code in xopt/pydantic.py
231 232 233 234 235 236 237 238 | |