Comments (5)
Let's take conv2d
since it's very similar to depthwiseConv2d
. Here are the lines that specify forward mode and gradients for conv2d. That op then uses 2 kernel/backend ops specified here.
DepthwiseConv2d is analogous but it's missing the gradients. You'd have to add depthwiseConv2dDerInput
and depthwiseConv2DDerFilter
to the backend. The math should be simpler than the conv2dDerInput
and conv2dDerFilter
. Hope this helps!
from tfjs.
Status on this? I'd really love to be able to calculate gradients for doing saliency maps.
from tfjs.
Is someone working on this? I'd like to get the gradients for MobileNet to perform finetuning in the browser and visualize features on the original image like Deepdream does.
After some digging through, I confirm the need for this ticket as part of my research and when I printed out filteredTape
in Engine.prototype.gradients()
, I also see some undefined layers interlaced between consecutive pairs of reshape ops (see pic). @nsthorat I see in #108 (comment) that the team is working on this, so I was wondering if I could be pointed somewhere.
Also, this comment is a followup to #153. Nikhil you said
We don't have gradients defined for depthwise convs, so MobileNet gradients should have worked in the old way.
I'm not sure what you mean by the old way. If you're referring to getting the gradients, that's precisely what we want. How do you go about it?
from tfjs.
You need the gradients for depthwise conv in order to analyze MobileNet's gradients. We will add this early next week. Stay tuned. In the meantime if anyone else is interested in taking a stab at this, I'll be happy to review.
from tfjs.
Gotcha. If I wanted to take a quick jab at it, what are some files I should specifically look out for?
My project deadline is next week so I'd like to have it added by early next week. I'd love to help given some pointers!
Thanks,
Jason
from tfjs.
Related Issues (20)
- a way to check if browser can run a model or not
- tf.fft rfft return tensor filled with 0 when given tensor with more than 150k element. HOT 8
- Hand-pose-detection react-native TypeError: Cannot read property 'prototype' of undefined HOT 4
- Bundle Size Issues HOT 6
- BlazePoseTfjsEstimationConfig - flipHorizontal do not work HOT 4
- @tensorflow/tfjs-node error on windows HOT 13
- Order of output heads from converted model keeps changing HOT 4
- Is there anything we can do about the JavaScript overhead that comes from predictions made in a loop?
- I'm running code of tensorflow/tfjs-node-gpu or tensorflow/tfjs-node after installation. I got an error. HOT 4
- Problem when installing tensorflowjs 3.18.0 HOT 5
- `tfjs-models/face-landmarks-detection`: `keypoint` `291` missing in `MEDIAPIPE_FACE_MESH_KEYPOINTS_BY_CONTOUR.lips` HOT 2
- Tensorflow model is working in python but converted tfjs model is not working HOT 7
- tidy function erase tensor before it can be used HOT 5
- `tf.einsum` appears incorrect for some cases HOT 2
- Installing tensorflow/tfjs-node fails on macOS Sonoma (14.3) on Apple Silicon ("Command failed: node-pre-gyp install --fallback-to-build HOT 11
- Tensorflow.js Converter: Usage of `save_format` when converting to graph model causes error on Keras 3 HOT 1
- [Codelab]: Making Predictions from 2D Data HOT 4
- Docs/readme left unfinished for model "face-landmarks-detection" HOT 4
- Error dumping weights duplicate weight name kernel HOT 9
- Loading movenet gives Uncaught (in promise) TypeError: Failed to fetch HOT 15
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 tfjs.