15
15
16
16
"""Algorithmic data generators for symbolic math tasks.
17
17
18
- See go/symbolic-math-dataset
19
18
"""
20
19
21
20
from __future__ import absolute_import
@@ -159,8 +158,6 @@ def random_expr(depth, vlist, ops):
159
158
def algebra_inverse_solve (left , right , var , solve_ops ):
160
159
"""Solves for the value of the given var in an expression.
161
160
162
- See go/symbolic-math-dataset.
163
-
164
161
Args:
165
162
left: The root of the ExprNode tree on the left side of the equals sign.
166
163
right: The root of the ExprNode tree on the right side of the equals sign.
@@ -243,8 +240,6 @@ def generate_algebra_inverse_sample(vlist, ops, solve_ops, min_depth,
243
240
Given an input equation and variable, produce the expression equal to the
244
241
variable.
245
242
246
- See go/symbolic-math-dataset.
247
-
248
243
Args:
249
244
vlist: Variable list. List of chars that can be used in the expression.
250
245
ops: List of ExprOp instances. The allowed operators for the expression.
@@ -284,8 +279,6 @@ def generate_algebra_simplify_sample(vlist, ops, min_depth, max_depth):
284
279
285
280
Given an input expression, produce the simplified expression.
286
281
287
- See go/symbolic-math-dataset.
288
-
289
282
Args:
290
283
vlist: Variable list. List of chars that can be used in the expression.
291
284
ops: List of ExprOp instances. The allowed operators for the expression.
@@ -312,8 +305,6 @@ def generate_calculus_integrate_sample(vlist, ops, min_depth, max_depth,
312
305
313
306
Given an input expression, produce the indefinite integral.
314
307
315
- See go/symbolic-math-dataset.
316
-
317
308
Args:
318
309
vlist: Variable list. List of chars that can be used in the expression.
319
310
ops: List of ExprOp instances. The allowed operators for the expression.
@@ -345,7 +336,7 @@ def generate_calculus_integrate_sample(vlist, ops, min_depth, max_depth,
345
336
346
337
347
338
# AlgebraConfig holds objects required to generate the algebra inverse
348
- # dataset. See go/symbolic-math-dataset.
339
+ # dataset.
349
340
# vlist: Variable list. A list of chars.
350
341
# dlist: Numberical digit list. A list of chars.
351
342
# flist: List of special function names. A list of chars.
@@ -367,8 +358,6 @@ def generate_calculus_integrate_sample(vlist, ops, min_depth, max_depth,
367
358
def math_dataset_init (alphabet_size = 26 , digits = None , functions = None ):
368
359
"""Initializes required objects to generate symbolic math datasets.
369
360
370
- See go/symbolic-math-dataset.
371
-
372
361
Produces token set, ExprOp instances, solve_op dictionary, encoders, and
373
362
decoders needed to generate the algebra inverse dataset.
374
363
0 commit comments