Comments (2)
Hey, @NirvikNU, thanks for the issue!
Judging by this line in the traceback
'form': lambda u, t: D(u, t) - 2 * np.pi * 2 * t^3
you're trying to solve an equation with t
cubed in the right-hand side of the equation. The thing is, exponentiation in Python
is performed using double stars **
. So, the line should look like
'form': lambda u, t: D(u, t) - 2 * np.pi * 2 * t**3
Best,
Alex
from pydens.
Sorry for posting the wrong traceback, this is the correct one:
Traceback (most recent call last):
File "<ipython-input-26-1b5c74329633>", line 1, in <module>
runfile('/home/nirvik/Documents/neuronal_model_python/temp.py', wdir='/home/nirvik/Documents/neuronal_model_python')
File "/usr/lib/python3/dist-packages/spyder/utils/site/sitecustomize.py", line 705, in runfile
execfile(filename, namespace)
File "/usr/lib/python3/dist-packages/spyder/utils/site/sitecustomize.py", line 102, in execfile
exec(compile(f.read(), filename, 'exec'), namespace)
File "/home/nirvik/Documents/neuronal_model_python/temp.py", line 38, in <module>
dg = Solver(config)
File "/home/nirvik/.local/lib/python3.6/site-packages/pydens/wrapper.py", line 21, in __init__
self.model = model_class(config)
File "/home/nirvik/.local/lib/python3.6/site-packages/pydens/batchflow/batchflow/models/tf/base.py", line 262, in __init__
super().__init__(*args, **kwargs)
File "/home/nirvik/.local/lib/python3.6/site-packages/pydens/batchflow/batchflow/models/base.py", line 38, in __init__
self.build(*args, **kwargs)
File "/home/nirvik/.local/lib/python3.6/site-packages/pydens/batchflow/batchflow/models/tf/base.py", line 331, in build
config = self.build_config()
File "/home/nirvik/.local/lib/python3.6/site-packages/pydens/model_tf.py", line 117, in build_config
n_parameters = get_num_parameters(form[0])
File "/home/nirvik/.local/lib/python3.6/site-packages/pydens/syntax_tree.py", line 77, in get_num_parameters
tree = form(*[SyntaxTreeNode('_' + str(i)) for i in range(n_args)])
File "/home/nirvik/Documents/neuronal_model_python/temp.py", line 25, in <lambda>
'form': lambda u, t: D(u, t) - 2 * np.pi * 2*t**3,
File "/home/nirvik/.local/lib/python3.6/site-packages/pydens/tokens.py", line 63, in <lambda>
if isinstance(args[0], SyntaxTreeNode) else method_(*args, **kwargs))
File "/home/nirvik/.local/lib/python3.6/site-packages/pydens/letters.py", line 82, in D
return np.stack([self.D(func, coordinate) for coordinate in coordinates],
TypeError: 'SyntaxTreeNode' object is not iterable
Also the same error persists with the original solved example for ODE I posted above.
from pydens.
Related Issues (20)
- Compilation error HOT 2
- boundry conditions HOT 1
- How can I change the interval of x HOT 3
- Elasticity Equations HOT 2
- How to install easily with PIP command? HOT 2
- Disentangle pydense and batchflow
- OperatorNotAllowedInGraphError: iterating over `tf.Tensor` is not allowed in Graph execution. Use Eager execution or decorate this function with @tf.function HOT 2
- How to solve Elliptic PDE with four different boundary conditions?
- Can anyone tell me the version of all the python packages installed?
- Create workflow to check installation
- Create workflow for releases
- Pyden Installation Problem HOT 1
- readme tanh,not tahn HOT 1
- How to solve if Parametric heat-equation in the example has 2 or 3 boundary conditions? HOT 2
- Learning from Data
- LBFGS optimizer not working
- Plotting problem HOT 1
- Systems of PDEs
- How to set an additional initial condition?
- Bug: type of missing layer (`ConvBlock`)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pydens.