1. 14 Mar, 2020 1 commit
  2. 16 Dec, 2019 1 commit
  3. 15 Dec, 2019 1 commit
  4. 14 Dec, 2019 2 commits
  5. 16 Oct, 2019 1 commit
    • Reed Wanderman-Milne's avatar
      Add support for the tf.keras.mixed_precision API in NCF · cb913691
      Reed Wanderman-Milne authored
      To test, I did 50 fp32 runs and 50 fp16 runs. I used the following command:
      
      python ncf_keras_main.py --dataset=ml-20m --num_gpus=1 --train_epochs=10 --clean --batch_size=99000 --learning_rate=0.00382059 --beta1=0.783529 --beta2=0.909003 --epsilon=1.45439e-7 --layers=256,256,128,64 --num_factors=64 --hr_threshold=0.635 --ml_perf --nouse_synthetic_data --data_dir ~/ncf_data_dir_python3 --model_dir ~/tmp_model_dir --keras_use_ctl
      
      For the fp16 runs, I added --dtype=fp16. The average hit-rate for both fp16 and fp32 was 0.6365. I also did 50 runs with the mixed precision graph rewrite, and the average hit-rate was 0.6363. The difference is likely due to noise.
      
      PiperOrigin-RevId: 275059871
      cb913691
  6. 17 Sep, 2019 1 commit
  7. 12 Aug, 2019 1 commit
    • Hongjun Choi's avatar
      Merged commit includes the following changes: (#7430) · 03b4a0af
      Hongjun Choi authored
      262988559  by A. Unique TensorFlower<gardener@tensorflow.org>:
      
          Enable NCF TF 2.0 model to run on TPUStrategy.
      
      --
      262971756  by A. Unique TensorFlower<gardener@tensorflow.org>:
      
          Internal change
      
      262967691  by hongkuny<hongkuny@google.com>:
      
          Internal
      
      --
      
      PiperOrigin-RevId: 262988559
      03b4a0af
  8. 28 Jun, 2019 1 commit
  9. 28 May, 2019 1 commit
  10. 22 Apr, 2019 1 commit
  11. 20 Apr, 2019 1 commit
    • Shining Sun's avatar
      Remove contrib imports, or move them inline (#6591) · 8ff9eb54
      Shining Sun authored
      * Remove contrib imports, or move them inline
      
      * Use exposed API for FixedLenFeature
      
      * Replace tf.logging with absl logging
      
      * Change GFile to v2 APIs
      
      * replace tf.logging with absl loggin in movielens
      
      * Fixing an import bug
      
      * Change gfile to v2 APIs in code
      
      * Swap to keras optimizer v2
      
      * Bug fix for optimizer
      
      * Change tf.log to tf.keras.backend.log
      
      * Change the loss function to keras loss
      
      * convert another loss to keras loss
      
      * Resolve comments and fix lint
      
      * Add a doc string
      
      * Fix existing tests and add new tests for DS
      
      * Added tests for multi-replica
      
      * Fix lint
      
      * resolve comments
      
      * make estimator run in tf2.0
      
      * use compat v1 loss
      
      * fix lint issue
      8ff9eb54
  12. 01 Mar, 2019 1 commit
    • Shining Sun's avatar
      Keras-fy NCF Model (#6092) · 048e5bff
      Shining Sun authored
      * tmp commit
      
      * tmp commit
      
      * first attempt (without eval)
      
      * Bug fixes
      
      * bug fixes
      
      * training done
      
      * Loss NAN, no eval
      
      * Loss weight problem solved
      
      * resolve the NAN loss problem
      
      * Problem solved. Clean up needed
      
      * Added a todo
      
      * Remove debug prints
      
      * Extract get_optimizer to ncf_common
      
      * Move metrics computation back to neumf; use DS.scope api
      
      * Extract DS.scope code to utils
      
      * lint fixes
      
      * Move obtaining DS above producer.start to avoid race condition
      
      * move pt 1
      
      * move pt 2
      
      * Update the run script
      
      * Wrap keras_model related code into functions
      
      * Update the doc for softmax_logitfy and change the method name
      
      * Resolve PR comments
      
      * working version with: eager, DS, batch and no masks
      
      * Remove git conflict indicator
      
      * move reshape to neumf_model
      
      * working version, not converge
      
      * converged
      
      * fix a test
      
      * more lint fix
      
      * more lint fix
      
      * more lint fixes
      
      * more lint fix
      
      * Removed unused imports
      
      * fix test
      
      * dummy commit for kicking of checks
      
      * fix lint issue
      
      * dummy input to kick off checks
      
      * dummy input to kick off checks
      
      * add collective to dist strat
      
      * addressed review comments
      
      * add a doc string
      048e5bff
  13. 07 Jan, 2019 1 commit
    • Taylor Robie's avatar
      rough pass at carving out existing NCF pipeline · c5ff4ec7
      Taylor Robie authored
      2nd half of rough replacement pass
      
      fix dataset map functions
      
      reduce bias in sample selection
      
      cache pandas work on a daily basis
      
      cleanup and fix batch check for multi gpu
      
      multi device fix
      
      fix treatment of eval data padding
      
      print data producer
      
      replace epoch overlap with padding and masking
      
      move type and shape info into the producer class and update run.sh with larger batch size hyperparams
      
      remove xla for multi GPU
      
      more cleanup
      
      remove model runner altogether
      
      bug fixes
      
      address subtle pipeline hang and improve producer __repr__
      
      fix crash
      
      fix assert
      
      use popen_helper to create pools
      
      add StreamingFilesDataset and abstract data storage to a separate class
      
      bug fix
      
      fix wait bug and add manual stack trace print
      
      more bug fixes and refactor valid point mask to work with TPU sharding
      
      misc bug fixes and adjust dtypes
      
      address crash from decoding bools
      
      fix remaining dtypes and change record writer pattern since it does not append
      
      fix synthetic data
      
      use TPUStrategy instead of TPUEstimator
      
      minor tweaks around moving to TPUStrategy
      
      cleanup some old code
      
      delint and simplify permutation generation
      
      remove low level tf layer definition, use single table with slice for keras, and misc fixes
      
      missed minor point on removing tf layer definition
      
      fix several bugs from recombinging layer definitions
      
      delint and add docstrings
      
      Update ncf_test.py. Section for identical inputs and different outputs was removed.
      
      update data test to run against the new producer class
      c5ff4ec7
  14. 01 Nov, 2018 1 commit
  15. 30 Oct, 2018 2 commits
  16. 29 Oct, 2018 1 commit
  17. 24 Oct, 2018 1 commit
    • Taylor Robie's avatar
      Add logging calls to NCF (#5576) · 780f5265
      Taylor Robie authored
      * first pass at __getattr__ abuse logger
      
      * first pass at adding tags to NCF
      
      * minor formatting updates
      
      * fix tag name
      
      * convert metrics to python floats
      
      * getting closer...
      
      * direct mlperf logs to a file
      
      * small tweaks and add stitching
      
      * update tags
      
      * fix tag and add a sudo call
      
      * tweak format of run.sh
      
      * delint
      
      * use distribution strategies for evaluation
      
      * address PR comments
      
      * delint and fix test
      
      * adjust flag validation for xla
      
      * add prefix to distinguish log stitching
      
      * fix index bug
      
      * fix clear cache for root user
      
      * dockerize cache drop
      
      * TIL some regex magic
      780f5265
  18. 20 Oct, 2018 1 commit
  19. 18 Oct, 2018 1 commit
  20. 17 Oct, 2018 2 commits
  21. 10 Oct, 2018 1 commit
  22. 03 Oct, 2018 1 commit
    • Taylor Robie's avatar
      Move evaluation to .evaluate() (#5413) · c494582f
      Taylor Robie authored
      * move evaluation from numpy to tensorflow
      
      fix syntax error
      
      don't use sigmoid to convert logits. there is too much precision loss.
      
      WIP: add logit metrics
      
      continue refactor of NCF evaluation
      
      fix syntax error
      
      fix bugs in eval loss calculation
      
      fix eval loss reweighting
      
      remove numpy based metric calculations
      
      fix logging hooks
      
      fix sigmoid to softmax bug
      
      fix comment
      
      catch rare PIPE error and address some PR comments
      
      * fix metric test and address PR comments
      
      * delint and fix python2
      
      * fix test and address PR comments
      
      * extend eval to TPUs
      c494582f
  23. 02 Oct, 2018 1 commit
  24. 20 Sep, 2018 1 commit
  25. 22 Aug, 2018 1 commit
    • Reed's avatar
      Fix convergence issues for MLPerf. (#5161) · 64710c05
      Reed authored
      * Fix convergence issues for MLPerf.
      
      Thank you to @robieta for helping me find these issues, and for providng an algorithm for the `get_hit_rate_and_ndcg_mlperf` function.
      
      This change causes every forked process to set a new seed, so that forked processes do not generate the same set of random numbers. This improves evaluation hit rates.
      
      Additionally, it adds a flag, --ml_perf, that makes further changes so that the evaluation hit rate can match the MLPerf reference implementation.
      
      I ran 4 times with --ml_perf and 4 times without. Without --ml_perf, the highest hit rates achieved by each run were 0.6278, 0.6287, 0.6289, and 0.6241. With --ml_perf, the highest hit rates were 0.6353, 0.6356, 0.6367, and 0.6353.
      
      * fix lint error
      
      * Fix failing test
      
      * Address @robieta's feedback
      
      * Address more feedback
      64710c05
  26. 01 Aug, 2018 1 commit
  27. 31 Jul, 2018 1 commit
  28. 30 Jul, 2018 1 commit
    • Taylor Robie's avatar
      NCF pipeline refactor (take 2) and initial TPU port. (#4935) · 6518c1c7
      Taylor Robie authored
      * intermediate commit
      
      * ncf now working
      
      * reorder pipeline
      
      * allow batched decode for file backed dataset
      
      * fix bug
      
      * more tweaks
      
      * parallize false negative generation
      
      * shared pool hack
      
      * workers ignore sigint
      
      * intermediate commit
      
      * simplify buffer backed dataset creation to fixed length record approach only. (more cleanup needed)
      
      * more tweaks
      
      * simplify pipeline
      
      * fix misplaced cleanup() calls. (validation works\!)
      
      * more tweaks
      
      * sixify memoryview usage
      
      * more sixification
      
      * fix bug
      
      * add future imports
      
      * break up training input pipeline
      
      * more pipeline tuning
      
      * first pass at moving negative generation to async
      
      * refactor async pipeline to use files instead of ipc
      
      * refactor async pipeline
      
      * move expansion and concatenation from reduce worker to generation workers
      
      * abandon complete async due to interactions with the tensorflow threadpool
      
      * cleanup
      
      * remove performance_comparison.py
      
      * experiment with rough generator + interleave pipeline
      
      * yet more pipeline tuning
      
      * update on-the-fly pipeline
      
      * refactor preprocessing, and move train generation behind a GRPC server
      
      * fix leftover call
      
      * intermediate commit
      
      * intermediate commit
      
      * fix index error in data pipeline, and add logging to train data server
      
      * make sharding more robust to imbalance
      
      * correctly sample with replacement
      
      * file buffers are no longer needed for this branch
      
      * tweak sampling methods
      
      * add README for data pipeline
      
      * fix eval sampling, and vectorize eval metrics
      
      * add spillover and static training batch sizes
      
      * clean up cruft from earlier iterations
      
      * rough delint
      
      * delint 2 / n
      
      * add type annotations
      
      * update run script
      
      * make run.sh a bit nicer
      
      * change embedding initializer to match reference
      
      * rough pass at pure estimator model_fn
      
      * impose static shape hack (revisit later)
      
      * refinements
      
      * fix dir error in run.sh
      
      * add documentation
      
      * add more docs and fix an assert
      
      * old data test is no longer valid. Keeping it around as reference for the new one
      
      * rough draft of data pipeline validation script
      
      * don't rely on shuffle default
      
      * tweaks and documentation
      
      * add separate eval batch size for performance
      
      * initial commit
      
      * terrible hacking
      
      * mini hacks
      
      * missed a bug
      
      * messing about trying to get TPU running
      
      * TFRecords based TPU attempt
      
      * bug fixes
      
      * don't log remotely
      
      * more bug fixes
      
      * TPU tweaks and bug fixes
      
      * more tweaks
      
      * more adjustments
      
      * rework model definition
      
      * tweak data pipeline
      
      * refactor async TFRecords generation
      
      * temp commit to run.sh
      
      * update log behavior
      
      * fix logging bug
      
      * add check for subprocess start to avoid cryptic hangs
      
      * unify deserialize and make it TPU compliant
      
      * delint
      
      * remove gRPC pipeline code
      
      * fix logging bug
      
      * delint and remove old test files
      
      * add unit tests for NCF pipeline
      
      * delint
      
      * clean up run.sh, and add run_tpu.sh
      
      * forgot the most important line
      
      * fix run.sh bugs
      
      * yet more bash debugging
      
      * small tweak to add keras summaries to model_fn
      
      * Clean up sixification issues
      
      * address PR comments
      
      * delinting is never over
      6518c1c7
  29. 20 Jun, 2018 1 commit
    • Taylor Robie's avatar
      Wide Deep refactor and deep movies (#4506) · 20070ca4
      Taylor Robie authored
      * begin branch
      
      * finish download script
      
      * rename download to dataset
      
      * intermediate commit
      
      * intermediate commit
      
      * misc tweaks
      
      * intermediate commit
      
      * intermediate commit
      
      * intermediate commit
      
      * delint and update census test.
      
      * add movie tests
      
      * delint
      
      * fix py2 issue
      
      * address PR comments
      
      * intermediate commit
      
      * intermediate commit
      
      * intermediate commit
      
      * finish wide deep transition to vanilla movielens
      
      * delint
      
      * intermediate commit
      
      * intermediate commit
      
      * intermediate commit
      
      * intermediate commit
      
      * fix import
      
      * add default ncf csv construction
      
      * change default on download_if_missing
      
      * shard and vectorize example serialization
      
      * fix import
      
      * update ncf data unittests
      
      * delint
      
      * delint
      
      * more delinting
      
      * fix wide-deep movielens serialization
      
      * address PR comments
      
      * add file_io tests
      
      * investigate wide-deep test failure
      
      * remove hard coded path and properly use flags.
      
      * address file_io test PR comments
      
      * missed a hash_bucked_size
      20070ca4
  30. 25 May, 2018 1 commit
  31. 22 May, 2018 1 commit
    • Yanhui Liang's avatar
      Add recommendation model (#4175) · 81d77669
      Yanhui Liang authored
      * Add recommendation model
      
      * Fix pylints check error
      
      * Rename file
      
      * Address comments, update input pipeline, and add distribution strategy
      
      * Fix import error
      
      * Address more comments
      
      * Fix lints
      81d77669