update instruction of the deprecated tensorflow dataset sliding window with tf.data.experimental.CsvDatasetTensorFlow 0.12 tutorials produce warning: "Rank of input Tensor should be the same as output_rank for columnHow to compile Tensorflow with SSE4.2 and AVX instructions?Changing Tensorflow number of convolutional and pooling layers using MNIST datasetYour CPU supports instructions that this TensorFlow binary was not compiled to use: AVX AVX2python ,1 positional argument but 2 were givenPreprocessing CSV data using tensorflow DataSet APITensorflow custom Estimator with Dataset API: embedding lookup (feature_column) NMT taskTensorflow: NotImplementedError: The reduce() transformation does not currently support nested datasets as inputsHow to translate deprecated tf.train.QueueRunners tensorflow approach to importing data to new tf.data.Dataset approachTensorflow dynamic_rnn deprecation

Why doesn't WotC use established keywords on all new cards?

Why do only some White Walkers shatter into ice chips?

Finding positions of minimum values in list

Fitch Proof Question

Does a card have a keyword if it has the same effect as said keyword?

Is there an idiom that support the idea that "inflation is bad"?

How was the quadratic formula created?

Would Hubble Space Telescope improve black hole image observed by EHT if it joined array of telesopes?

How long would it take for people to notice a mass disappearance?

Would glacier 'trees' be plausible?

Using column size much larger than necessary

What's preferable: to count Sefiras Haomer right at nightfall by oneself OR to count later with a Ma'ariv minyan?

I need a disease

Out of scope work duties and resignation

Why Isn’t SQL More Refactorable?

I have a unique character that I'm having a problem writing. He's a virus!

Point of the the Dothraki's attack in GoT S8E3?

Where can I go to avoid planes overhead?

What happens if you dump antimatter into a black hole?

Position of past participle and extent of the Verbklammer

If your medical expenses exceed your income does the IRS pay you?

How I can I roll a number of non-digital dice to get a random number between 1 and 150?

Manager is threatening to grade me poorly if I don't complete the project

Have I damaged my car by attempting to reverse with hand/park brake up?



update instruction of the deprecated tensorflow dataset sliding window with tf.data.experimental.CsvDataset


TensorFlow 0.12 tutorials produce warning: "Rank of input Tensor should be the same as output_rank for columnHow to compile Tensorflow with SSE4.2 and AVX instructions?Changing Tensorflow number of convolutional and pooling layers using MNIST datasetYour CPU supports instructions that this TensorFlow binary was not compiled to use: AVX AVX2python ,1 positional argument but 2 were givenPreprocessing CSV data using tensorflow DataSet APITensorflow custom Estimator with Dataset API: embedding lookup (feature_column) NMT taskTensorflow: NotImplementedError: The reduce() transformation does not currently support nested datasets as inputsHow to translate deprecated tf.train.QueueRunners tensorflow approach to importing data to new tf.data.Dataset approachTensorflow dynamic_rnn deprecation






.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty height:90px;width:728px;box-sizing:border-box;








1















I am trying without success to update my code with the instruction given in the tensorflow documentation (api r1.13). I am using the tf.data.experimental.CsvDataset and the deprecated tf.contrib.data.sliding_window_batch for a RNN and all works fine (except the deprecated sliding_window warning message).



For the update I have simply replaced



dataset = dataset.apply(tf.contrib.data.sliding_window_batch(batch_size, 1))


with



dataset = dataset.window(size=batch_size, stride=1).flat_map(lambda x: x.batch(batch_size))


and I got the following error for a csv file with 50 columns:



TypeError: <lambda>() takes 1 positional argument but 50 were given


How can I solve this problem for any csv file (with any number of columns)?










share|improve this question




























    1















    I am trying without success to update my code with the instruction given in the tensorflow documentation (api r1.13). I am using the tf.data.experimental.CsvDataset and the deprecated tf.contrib.data.sliding_window_batch for a RNN and all works fine (except the deprecated sliding_window warning message).



    For the update I have simply replaced



    dataset = dataset.apply(tf.contrib.data.sliding_window_batch(batch_size, 1))


    with



    dataset = dataset.window(size=batch_size, stride=1).flat_map(lambda x: x.batch(batch_size))


    and I got the following error for a csv file with 50 columns:



    TypeError: <lambda>() takes 1 positional argument but 50 were given


    How can I solve this problem for any csv file (with any number of columns)?










    share|improve this question
























      1












      1








      1








      I am trying without success to update my code with the instruction given in the tensorflow documentation (api r1.13). I am using the tf.data.experimental.CsvDataset and the deprecated tf.contrib.data.sliding_window_batch for a RNN and all works fine (except the deprecated sliding_window warning message).



      For the update I have simply replaced



      dataset = dataset.apply(tf.contrib.data.sliding_window_batch(batch_size, 1))


      with



      dataset = dataset.window(size=batch_size, stride=1).flat_map(lambda x: x.batch(batch_size))


      and I got the following error for a csv file with 50 columns:



      TypeError: <lambda>() takes 1 positional argument but 50 were given


      How can I solve this problem for any csv file (with any number of columns)?










      share|improve this question














      I am trying without success to update my code with the instruction given in the tensorflow documentation (api r1.13). I am using the tf.data.experimental.CsvDataset and the deprecated tf.contrib.data.sliding_window_batch for a RNN and all works fine (except the deprecated sliding_window warning message).



      For the update I have simply replaced



      dataset = dataset.apply(tf.contrib.data.sliding_window_batch(batch_size, 1))


      with



      dataset = dataset.window(size=batch_size, stride=1).flat_map(lambda x: x.batch(batch_size))


      and I got the following error for a csv file with 50 columns:



      TypeError: <lambda>() takes 1 positional argument but 50 were given


      How can I solve this problem for any csv file (with any number of columns)?







      python-3.x csv tensorflow deprecated sliding-window






      share|improve this question













      share|improve this question











      share|improve this question




      share|improve this question










      asked Mar 22 at 22:33









      UrianUrian

      234




      234






















          0






          active

          oldest

          votes












          Your Answer






          StackExchange.ifUsing("editor", function ()
          StackExchange.using("externalEditor", function ()
          StackExchange.using("snippets", function ()
          StackExchange.snippets.init();
          );
          );
          , "code-snippets");

          StackExchange.ready(function()
          var channelOptions =
          tags: "".split(" "),
          id: "1"
          ;
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function()
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled)
          StackExchange.using("snippets", function()
          createEditor();
          );

          else
          createEditor();

          );

          function createEditor()
          StackExchange.prepareEditor(
          heartbeatType: 'answer',
          autoActivateHeartbeat: false,
          convertImagesToLinks: true,
          noModals: true,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: 10,
          bindNavPrevention: true,
          postfix: "",
          imageUploader:
          brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
          contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
          allowUrls: true
          ,
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          );



          );













          draft saved

          draft discarded


















          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55308630%2fupdate-instruction-of-the-deprecated-tensorflow-dataset-sliding-window-with-tf-d%23new-answer', 'question_page');

          );

          Post as a guest















          Required, but never shown

























          0






          active

          oldest

          votes








          0






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes















          draft saved

          draft discarded
















































          Thanks for contributing an answer to Stack Overflow!


          • Please be sure to answer the question. Provide details and share your research!

          But avoid


          • Asking for help, clarification, or responding to other answers.

          • Making statements based on opinion; back them up with references or personal experience.

          To learn more, see our tips on writing great answers.




          draft saved


          draft discarded














          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55308630%2fupdate-instruction-of-the-deprecated-tensorflow-dataset-sliding-window-with-tf-d%23new-answer', 'question_page');

          );

          Post as a guest















          Required, but never shown





















































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown

































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown







          Popular posts from this blog

          Kamusi Yaliyomo Aina za kamusi | Muundo wa kamusi | Faida za kamusi | Dhima ya picha katika kamusi | Marejeo | Tazama pia | Viungo vya nje | UrambazajiKuhusu kamusiGo-SwahiliWiki-KamusiKamusi ya Kiswahili na Kiingerezakuihariri na kuongeza habari

          SQL error code 1064 with creating Laravel foreign keysForeign key constraints: When to use ON UPDATE and ON DELETEDropping column with foreign key Laravel error: General error: 1025 Error on renameLaravel SQL Can't create tableLaravel Migration foreign key errorLaravel php artisan migrate:refresh giving a syntax errorSQLSTATE[42S01]: Base table or view already exists or Base table or view already exists: 1050 Tableerror in migrating laravel file to xampp serverSyntax error or access violation: 1064:syntax to use near 'unsigned not null, modelName varchar(191) not null, title varchar(191) not nLaravel cannot create new table field in mysqlLaravel 5.7:Last migration creates table but is not registered in the migration table

          은진 송씨 목차 역사 본관 분파 인물 조선 왕실과의 인척 관계 집성촌 항렬자 인구 같이 보기 각주 둘러보기 메뉴은진 송씨세종실록 149권, 지리지 충청도 공주목 은진현