Comments (2)
Remove F and L expression
Since pipeline has several options to call an external function, we might get rid of F
and L
expressions, thus simplifying the API and free letters for new expressions.
pipeline.call(external_func, B(), V.some_var, dst=V('other_var'))
pipeline
.add_namespace(some_module)
.external_func(B(), V.some_var, dst=V('other_var'))
So instead of
pipeline.train_model('model', feed_dict=F(make_data)(B.images, V.some_var)
(1)
you will write:
pipeline
.call(make_data, B.images, V.some_var, dst=V('feed_dict'))
.train_model('model', feed_dict=V.feed_dict)
or even
pipeline
.make_data(B.images, V.some_var, dst=V('feed_dict'))
.train_model('model', feed_dict=V.feed_dict)
While the first version (1) is shorter, the proposed change might seem less obscure and implicit.
from batchflow.
Separate a computed NE and a reference NE
While this works well for C
, D
, B
and V
, the logic breaks when it comes to R
, P
, F
.
For instance, when you write R('normal', 0, 1)
, you rather want to compute the values and pass them, not the NE itself.
As a result, when you see NE(...)
you still don't know whether the values should be passed or NE.
Consequently, the action might need to recompute all the parameters, which is inefficient.
So, let's use W
as a container to pass NE further. And later we might also add parameters for @action
decorator to specify arguments which should be passed "as is" and not be computed in the pipeline.
Remove F and L expression
Sometimes L
might be helpful to pass a callable with params, so it is a declarative version of partial
.
So I'll remove F
and rename L
to F
for clarity. :-)
from batchflow.
Related Issues (20)
- Add EfficientNet for TorchModel HOT 1
- Update requirements HOT 1
- Dropblock for Torch
- Add CII Best Practices Badge
- Fix installation test workflow for forks HOT 1
- Minimize requirements
- Fix Pyramidal layers
- RuntimeError: generator raised StopIteration
- Initialize random seed for processes
- Move research utils to research module
- Typo
- `TorchModel` improvements HOT 2
- Refactor `inbatch_parallel` HOT 2
- Reporting a vulnerability
- `__repr__` of `Config` return keys in the wrong order
- Add smth like 'disable_axis' to `plot`
- Paths in `Config` as keys HOT 1
- Test install for all supported Pythons: 3.8 - 3.12
- Remove `gpu` functions
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 batchflow.