Conversation
|
in the description/readme could you clarify the 3rd way in some more details? i guess you mean to write a model in python TF/keras and then saving. this is in can you link to our documentation somehow how to take python TF/keras models and convert it to TFjs? how about the preprocessing pipeline in this case? i guess it remains in python but how did you abstract it? were you able to test the resulting JS model if it does the same as the pytorch python one? maybe with and without preprocessing? |
|
Did the 70MB+ files "output" needed to be pushed in Git? @s314cy worked a lot to clean the Git history to get a light repo |
yes, such heavy static files should not be pushed to the repo, even if not merged in dev/prod, since the repo will keep track of the files as long as they exist in some commit in some remote branch (so it won't be enough to remove them and commit) a good solution would be for the branch to only contain the source code that generated the static model files that were pushed; the latter can be gitignored (note that logs and other situational files should not be pushed either, thus they can be gitignored as well) technically, this means adding all the log, onnx and bin files to the gitignore, git rm them, commit, squash the git rm commit with the commit that added the files, and finally push force |
491040e to
e6cb7df
Compare
Running the script yields a .txt file containing a certain amount of floating point values, which will be a multiple of 32. In order to use the TensorflowJS model on the data, read values from the text file by loading them in a float tensor of size [32,-1].
|
|
@walidabn should I merge this once the |
1826b55 to
516539d
Compare
…on on custom preprocessing in JS vs Python in TASK
516539d to
cae03a4
Compare
Fixes issue @480 in the following sense :
This PR is not meant to be merged on develop, but essentially brings the DeepBreath model to JS. In more details :
A few notes : When converting from Pytorch to Tensorflow/TFJS, unless the model is trivial, we should not rely on automatic conversion tools like pytorch2keras, or onnx2keras, as these libraries are out of date and don't support many layers/essential functionalities. Redevelopping the model manually on Tensorflow is the best way to go for these kind of tasks.