and these lines will appear:You can find the C code in this temporary file: C:\Users…\AppData\Local\Temp\theano_compilation_error_z7al6yx8
Exception Traceback (most recent call last)
in
15 t_obs = pm.Normal(“t_obs”, mu=water_head(50, T, S, 60, time_data), sigma=sigma, observed=T_data)
16
—> 17 trace = pm.sample(draws=2000, tune=1000)
18 save_trace= pm.save_trace(trace, ‘my_trace’, overwrite=True)
~.conda\envs\mypm3env\lib\site-packages\pymc3\sampling.py in sample(draws, step, init, n_init, start, trace, chain_idx, chains, cores, tune, progressbar, model, random_seed, discard_tuned_samples, compute_convergence_checks, callback, jitter_max_retries, return_inferencedata, idata_kwargs, mp_ctx, pickle_backend, **kwargs)
494 # By default, try to use NUTS
495 log.info(“Auto-assigning NUTS sampler…”)
→ 496 start, step = init_nuts(
497 init=init,
498 chains=chains,
~.conda\envs\mypm3env\lib\site-packages\pymc3\sampling.py in init_nuts(init, chains, n_init, model, random_seed, progressbar, jitter_max_retries, **kwargs)
2185 raise ValueError(f"Unknown initializer: {init}.")
2186
→ 2187 step = pm.NUTS(potential=potential, model=model, **kwargs)
2188
2189 return start, step
~.conda\envs\mypm3env\lib\site-packages\pymc3\step_methods\hmc\nuts.py in init(self, vars, max_treedepth, early_max_treedepth, **kwargs)
166 pm.sample
to the desired number of tuning steps.
167 “”"
→ 168 super().init(vars, **kwargs)
169
170 self.max_treedepth = max_treedepth
~.conda\envs\mypm3env\lib\site-packages\pymc3\step_methods\hmc\base_hmc.py in init(self, vars, scaling, step_scale, is_cov, model, blocked, potential, dtype, Emax, target_accept, gamma, k, t0, adapt_step_size, step_rand, **theano_kwargs)
86 vars = inputvars(vars)
87
—> 88 super().init(vars, blocked=blocked, model=model, dtype=dtype, **theano_kwargs)
89
90 self.adapt_step_size = adapt_step_size
~.conda\envs\mypm3env\lib\site-packages\pymc3\step_methods\arraystep.py in init(self, vars, model, blocked, dtype, logp_dlogp_func, **theano_kwargs)
252
253 if logp_dlogp_func is None:
→ 254 func = model.logp_dlogp_function(vars, dtype=dtype, **theano_kwargs)
255 else:
256 func = logp_dlogp_func
~.conda\envs\mypm3env\lib\site-packages\pymc3\model.py in logp_dlogp_function(self, grad_vars, tempered, **kwargs)
1002 varnames = [var.name for var in grad_vars]
1003 extra_vars = [var for var in self.free_RVs if var.name not in varnames]
→ 1004 return ValueGradFunction(costs, grad_vars, extra_vars, **kwargs)
1005
1006 @property
~.conda\envs\mypm3env\lib\site-packages\pymc3\model.py in init(self, costs, grad_vars, extra_vars, dtype, casting, compute_grads, **kwargs)
689
690 if compute_grads:
→ 691 grad = tt.grad(self._cost_joined, self._vars_joined)
692 grad.name = “__grad”
693 outputs = [self._cost_joined, grad]
~.conda\envs\mypm3env\lib\site-packages\theano\gradient.py in grad(cost, wrt, consider_constant, disconnected_inputs, add_names, known_grads, return_disconnected, null_gradients)
637 assert g.type.dtype in theano.tensor.float_dtypes
638
→ 639 rval = _populate_grad_dict(var_to_app_to_idx, grad_dict, wrt, cost_name)
640
641 for i in range(len(rval)):
~.conda\envs\mypm3env\lib\site-packages\theano\gradient.py in _populate_grad_dict(var_to_app_to_idx, grad_dict, wrt, cost_name)
1438 return grad_dict[var]
1439
→ 1440 rval = [access_grad_cache(elem) for elem in wrt]
1441
1442 return rval
~.conda\envs\mypm3env\lib\site-packages\theano\gradient.py in (.0)
1438 return grad_dict[var]
1439
→ 1440 rval = [access_grad_cache(elem) for elem in wrt]
1441
1442 return rval
~.conda\envs\mypm3env\lib\site-packages\theano\gradient.py in access_grad_cache(var)
1391 for idx in node_to_idx[node]:
1392
→ 1393 term = access_term_cache(node)[idx]
1394
1395 if not isinstance(term, Variable):
~.conda\envs\mypm3env\lib\site-packages\theano\gradient.py in access_term_cache(node)
1059 inputs = node.inputs
1060
→ 1061 output_grads = [access_grad_cache(var) for var in node.outputs]
1062
1063 # list of bools indicating if each output is connected to the cost
~.conda\envs\mypm3env\lib\site-packages\theano\gradient.py in (.0)
1059 inputs = node.inputs
1060
→ 1061 output_grads = [access_grad_cache(var) for var in node.outputs]
1062
1063 # list of bools indicating if each output is connected to the cost
~.conda\envs\mypm3env\lib\site-packages\theano\gradient.py in access_grad_cache(var)
1391 for idx in node_to_idx[node]:
1392
→ 1393 term = access_term_cache(node)[idx]
1394
1395 if not isinstance(term, Variable):
~.conda\envs\mypm3env\lib\site-packages\theano\gradient.py in access_term_cache(node)
1059 inputs = node.inputs
1060
→ 1061 output_grads = [access_grad_cache(var) for var in node.outputs]
1062
1063 # list of bools indicating if each output is connected to the cost
~.conda\envs\mypm3env\lib\site-packages\theano\gradient.py in (.0)
1059 inputs = node.inputs
1060
→ 1061 output_grads = [access_grad_cache(var) for var in node.outputs]
1062
1063 # list of bools indicating if each output is connected to the cost
~.conda\envs\mypm3env\lib\site-packages\theano\gradient.py in access_grad_cache(var)
1391 for idx in node_to_idx[node]:
1392
→ 1393 term = access_term_cache(node)[idx]
1394
1395 if not isinstance(term, Variable):
~.conda\envs\mypm3env\lib\site-packages\theano\gradient.py in access_term_cache(node)
1059 inputs = node.inputs
1060
→ 1061 output_grads = [access_grad_cache(var) for var in node.outputs]
1062
1063 # list of bools indicating if each output is connected to the cost
~.conda\envs\mypm3env\lib\site-packages\theano\gradient.py in (.0)
1059 inputs = node.inputs
1060
→ 1061 output_grads = [access_grad_cache(var) for var in node.outputs]
1062
1063 # list of bools indicating if each output is connected to the cost
~.conda\envs\mypm3env\lib\site-packages\theano\gradient.py in access_grad_cache(var)
1391 for idx in node_to_idx[node]:
1392
→ 1393 term = access_term_cache(node)[idx]
1394
1395 if not isinstance(term, Variable):
~.conda\envs\mypm3env\lib\site-packages\theano\gradient.py in access_term_cache(node)
1059 inputs = node.inputs
1060
→ 1061 output_grads = [access_grad_cache(var) for var in node.outputs]
1062
1063 # list of bools indicating if each output is connected to the cost
~.conda\envs\mypm3env\lib\site-packages\theano\gradient.py in (.0)
1059 inputs = node.inputs
1060
→ 1061 output_grads = [access_grad_cache(var) for var in node.outputs]
1062
1063 # list of bools indicating if each output is connected to the cost
~.conda\envs\mypm3env\lib\site-packages\theano\gradient.py in access_grad_cache(var)
1391 for idx in node_to_idx[node]:
1392
→ 1393 term = access_term_cache(node)[idx]
1394
1395 if not isinstance(term, Variable):
~.conda\envs\mypm3env\lib\site-packages\theano\gradient.py in access_term_cache(node)
1059 inputs = node.inputs
1060
→ 1061 output_grads = [access_grad_cache(var) for var in node.outputs]
1062
1063 # list of bools indicating if each output is connected to the cost
~.conda\envs\mypm3env\lib\site-packages\theano\gradient.py in (.0)
1059 inputs = node.inputs
1060
→ 1061 output_grads = [access_grad_cache(var) for var in node.outputs]
1062
1063 # list of bools indicating if each output is connected to the cost
~.conda\envs\mypm3env\lib\site-packages\theano\gradient.py in access_grad_cache(var)
1391 for idx in node_to_idx[node]:
1392
→ 1393 term = access_term_cache(node)[idx]
1394
1395 if not isinstance(term, Variable):
~.conda\envs\mypm3env\lib\site-packages\theano\gradient.py in access_term_cache(node)
1059 inputs = node.inputs
1060
→ 1061 output_grads = [access_grad_cache(var) for var in node.outputs]
1062
1063 # list of bools indicating if each output is connected to the cost
~.conda\envs\mypm3env\lib\site-packages\theano\gradient.py in (.0)
1059 inputs = node.inputs
1060
→ 1061 output_grads = [access_grad_cache(var) for var in node.outputs]
1062
1063 # list of bools indicating if each output is connected to the cost
~.conda\envs\mypm3env\lib\site-packages\theano\gradient.py in access_grad_cache(var)
1391 for idx in node_to_idx[node]:
1392
→ 1393 term = access_term_cache(node)[idx]
1394
1395 if not isinstance(term, Variable):
~.conda\envs\mypm3env\lib\site-packages\theano\gradient.py in access_term_cache(node)
1059 inputs = node.inputs
1060
→ 1061 output_grads = [access_grad_cache(var) for var in node.outputs]
1062
1063 # list of bools indicating if each output is connected to the cost
~.conda\envs\mypm3env\lib\site-packages\theano\gradient.py in (.0)
1059 inputs = node.inputs
1060
→ 1061 output_grads = [access_grad_cache(var) for var in node.outputs]
1062
1063 # list of bools indicating if each output is connected to the cost
~.conda\envs\mypm3env\lib\site-packages\theano\gradient.py in access_grad_cache(var)
1391 for idx in node_to_idx[node]:
1392
→ 1393 term = access_term_cache(node)[idx]
1394
1395 if not isinstance(term, Variable):
~.conda\envs\mypm3env\lib\site-packages\theano\gradient.py in access_term_cache(node)
1059 inputs = node.inputs
1060
→ 1061 output_grads = [access_grad_cache(var) for var in node.outputs]
1062
1063 # list of bools indicating if each output is connected to the cost
~.conda\envs\mypm3env\lib\site-packages\theano\gradient.py in (.0)
1059 inputs = node.inputs
1060
→ 1061 output_grads = [access_grad_cache(var) for var in node.outputs]
1062
1063 # list of bools indicating if each output is connected to the cost
~.conda\envs\mypm3env\lib\site-packages\theano\gradient.py in access_grad_cache(var)
1391 for idx in node_to_idx[node]:
1392
→ 1393 term = access_term_cache(node)[idx]
1394
1395 if not isinstance(term, Variable):
~.conda\envs\mypm3env\lib\site-packages\theano\gradient.py in access_term_cache(node)
1059 inputs = node.inputs
1060
→ 1061 output_grads = [access_grad_cache(var) for var in node.outputs]
1062
1063 # list of bools indicating if each output is connected to the cost
~.conda\envs\mypm3env\lib\site-packages\theano\gradient.py in (.0)
1059 inputs = node.inputs
1060
→ 1061 output_grads = [access_grad_cache(var) for var in node.outputs]
1062
1063 # list of bools indicating if each output is connected to the cost
~.conda\envs\mypm3env\lib\site-packages\theano\gradient.py in access_grad_cache(var)
1391 for idx in node_to_idx[node]:
1392
→ 1393 term = access_term_cache(node)[idx]
1394
1395 if not isinstance(term, Variable):
~.conda\envs\mypm3env\lib\site-packages\theano\gradient.py in access_term_cache(node)
1059 inputs = node.inputs
1060
→ 1061 output_grads = [access_grad_cache(var) for var in node.outputs]
1062
1063 # list of bools indicating if each output is connected to the cost
~.conda\envs\mypm3env\lib\site-packages\theano\gradient.py in (.0)
1059 inputs = node.inputs
1060
→ 1061 output_grads = [access_grad_cache(var) for var in node.outputs]
1062
1063 # list of bools indicating if each output is connected to the cost
~.conda\envs\mypm3env\lib\site-packages\theano\gradient.py in access_grad_cache(var)
1391 for idx in node_to_idx[node]:
1392
→ 1393 term = access_term_cache(node)[idx]
1394
1395 if not isinstance(term, Variable):
~.conda\envs\mypm3env\lib\site-packages\theano\gradient.py in access_term_cache(node)
1218 )
1219
→ 1220 input_grads = node.op.L_op(inputs, node.outputs, new_output_grads)
1221
1222 if input_grads is None:
~.conda\envs\mypm3env\lib\site-packages\theano\tensor\elemwise.py in L_op(self, inputs, outs, ograds)
562
563 # compute grad with respect to broadcasted input
→ 564 rval = self._bgrad(inputs, outs, ograds)
565
566 # TODO: make sure that zeros are clearly identifiable
~.conda\envs\mypm3env\lib\site-packages\theano\tensor\elemwise.py in _bgrad(self, inputs, outputs, ograds)
666 ret.append(None)
667 continue
→ 668 ret.append(transform(scalar_igrad))
669
670 return ret
~.conda\envs\mypm3env\lib\site-packages\theano\tensor\elemwise.py in transform(r)
657 return DimShuffle((), [“x”] * nd)(res)
658
→ 659 new_r = Elemwise(node.op, {})(*[transform(ipt) for ipt in node.inputs])
660 return new_r
661
~.conda\envs\mypm3env\lib\site-packages\theano\tensor\elemwise.py in (.0)
657 return DimShuffle((), [“x”] * nd)(res)
658
→ 659 new_r = Elemwise(node.op, {})(*[transform(ipt) for ipt in node.inputs])
660 return new_r
661
~.conda\envs\mypm3env\lib\site-packages\theano\tensor\elemwise.py in transform(r)
657 return DimShuffle((), [“x”] * nd)(res)
658
→ 659 new_r = Elemwise(node.op, {})(*[transform(ipt) for ipt in node.inputs])
660 return new_r
661
~.conda\envs\mypm3env\lib\site-packages\theano\graph\op.py in call(self, *inputs, **kwargs)
251
252 if config.compute_test_value != “off”:
→ 253 compute_test_value(node)
254
255 if self.default_output is not None:
~.conda\envs\mypm3env\lib\site-packages\theano\graph\op.py in compute_test_value(node)
124
125 # Create a thunk that performs the computation
→ 126 thunk = node.op.make_thunk(node, storage_map, compute_map, no_recycling=[])
127 thunk.inputs = [storage_map[v] for v in node.inputs]
128 thunk.outputs = [storage_map[v] for v in node.outputs]
~.conda\envs\mypm3env\lib\site-packages\theano\graph\op.py in make_thunk(self, node, storage_map, compute_map, no_recycling, impl)
632 )
633 try:
→ 634 return self.make_c_thunk(node, storage_map, compute_map, no_recycling)
635 except (NotImplementedError, MethodNotDefined):
636 # We requested the c code, so don’t catch the error.
~.conda\envs\mypm3env\lib\site-packages\theano\graph\op.py in make_c_thunk(self, node, storage_map, compute_map, no_recycling)
598 print(f"Disabling C code for {self} due to unsupported float16")
599 raise NotImplementedError(“float16”)
→ 600 outputs = cl.make_thunk(
601 input_storage=node_input_storage, output_storage=node_output_storage
602 )
~.conda\envs\mypm3env\lib\site-packages\theano\link\c\basic.py in make_thunk(self, input_storage, output_storage, storage_map)
1201 “”"
1202 init_tasks, tasks = self.get_init_tasks()
→ 1203 cthunk, module, in_storage, out_storage, error_storage = self.compile(
1204 input_storage, output_storage, storage_map
1205 )
~.conda\envs\mypm3env\lib\site-packages\theano\link\c\basic.py in compile(self, input_storage, output_storage, storage_map)
1136 input_storage = tuple(input_storage)
1137 output_storage = tuple(output_storage)
→ 1138 thunk, module = self.cthunk_factory(
1139 error_storage,
1140 input_storage,
~.conda\envs\mypm3env\lib\site-packages\theano\link\c\basic.py in cthunk_factory(self, error_storage, in_storage, out_storage, storage_map)
1632 for node in self.node_order:
1633 node.op.prepare_node(node, storage_map, None, “c”)
→ 1634 module = get_module_cache().module_from_key(key=key, lnk=self)
1635
1636 vars = self.inputs + self.outputs + self.orphans
~.conda\envs\mypm3env\lib\site-packages\theano\link\c\cmodule.py in module_from_key(self, key, lnk)
1189 try:
1190 location = dlimport_workdir(self.dirname)
→ 1191 module = lnk.compile_cmodule(location)
1192 name = module.file
1193 assert name.startswith(location)
~.conda\envs\mypm3env\lib\site-packages\theano\link\c\basic.py in compile_cmodule(self, location)
1541 try:
1542 _logger.debug(f"LOCATION {location}")
→ 1543 module = c_compiler.compile_str(
1544 module_name=mod.code_hash,
1545 src_code=src_code,
~.conda\envs\mypm3env\lib\site-packages\theano\link\c\cmodule.py in compile_str(module_name, src_code, location, include_dirs, lib_dirs, libs, preargs, py_module, hide_symbols)
2544 # difficult to read.
2545 compile_stderr = compile_stderr.replace("\n", ". “)
→ 2546 raise Exception(
2547 f"Compilation failed (return status={status}): {compile_stderr}”
2548 )
Exception: ('Compilation failed (return status=1):