How to get the dimensions of a tensor (in TensorFlow) at graph construction time?

I am trying an Op that is not behaving as expected. ``` graph = tf.Graph() with graph.as_default(): train_dataset = tf.placeholder(tf.int32, shape=[128, 2]) embeddings = tf.Variable( tf.rando...

WooCommerce: Finding the products in database

I'm creating a website using WooCommerce and I want to restrict the available products to users depending on the postcode that they enter in the search form on my home page. To be able to achieve th...

System.Speech.Recognition alternative matches and confidence values

I am using the `System.Speech.Recognition` namespace to recognize a spoken sentence. I am interested in the alternative sentences the recognizer provides, alongside with their confidence scores. From ...

10 May at 08:50

Visual Studio Code: Take Input From User

Currently, I'm trying to write C/C++ program in Visual Studio code. For this I've installed two extensions: [C/C++](https://blogs.msdn.microsoft.com/vcblog/2016/03/31/cc-extension-for-visual-studio-co...

1 May at 09:7

What's the difference between the new netstandardapp and netcoreapp TFMs?

I noticed that NuGet has recently added support for several new TFMs related to .NET Core, including: - `netstandard`- `netstandardapp`- `netcoreapp` To the best of my knowledge, `netstandard` is th...

Can I use ServiceStack routes with method parameters instead of a DTO class for every request?

I love the capability of ASP.NET MVC controllers, in terms of being able to add a route attribute that maps a certain part of the URL to a method parameter, i.e.: ``` [Route("there/are/{howManyDucks}...

1 May at 02:1

How to create a form in a pop-up using xamarin.forms?

I'm using Xamarin.forms and I need to have a login form in a popup view like in the following image: [](https://i.stack.imgur.com/zkS8X.png) Right now I'm using PushModalAsync, however this makes th...

Where should I put Database.EnsureCreated?

I have an Entity Framework Core + ASP.NET Core application and when my application starts up I want to ensure that the database is created, and eventually (once I have migrations) I want to ensure tha...

30 Apr at 17:58

SignalR 2.2 clients not receiving any messages

I have a self-hosted SignalR application running in the context of a console app. I'm connecting to the hubs within it through the use of a wrapper class to prevent me from having to reference the Sig...

2 May at 17:34

How to return history of validation loss in Keras

Using Anaconda Python 2.7 Windows 10. I am training a language model using the Keras exmaple: ``` print('Build model...') model = Sequential() model.add(GRU(512, return_sequences=True, input_shape=(...

Make video fit 100% with any screen resolution

I have a video with the following properties, Frame width: 1920 and Frame Height: 1080. I need its width and height to be 100% thus filling up the whole screen. And it needs to be responsive too. So f...

Set RabbitMq .outq as durable with ServiceStack

Our queues are automatically created when calling mqServer.CreateMessageQueueClient().Publish(). Recently we had an issue with a RabbitMq server going down and since ServiceStack does not create the o...

30 Apr at 00:29

How to generate range of numbers from 0 to n in ES2015 only?

I have always found the `range` function missing from JavaScript as it is available in python and others? Is there any concise way to generate range of numbers in ES2015 ? EDIT: MY question is differ...

17 Jun at 08:17

Validating an email string in .net using EmailAddressAttribute, but not on an attribute

I want to be able to do this: ``` string email = "some@email.com"; bool isValid = IsValidEmail(email); //returns true ``` ...but use the logic Microsoft has already given us in . There are hundred...

29 Apr at 22:39

Angular 2 beta.17: Property 'map' does not exist on type 'Observable<Response>'

I just upgraded from Angular 2 to , which in turn requires rxjs 5.0.0-beta.6. (Changelog here: [https://github.com/angular/angular/blob/master/CHANGELOG.md#200-beta17-2016-04-28](https://github.com/a...

18 Sep at 12:9

Dapper Parameter replace not working for Top

This is my sql ``` var maxLimit =100; var sql = "Select Top @MaxLimit from Table WHere data =@Id" conn.Query<Result>(sql, new { Id = customerId, MaxLimit = maxLimit ...

29 Apr at 20:31

Keras model.summary() result - Understanding the # of Parameters

I have a simple NN model for detecting hand-written digits from a 28x28px image written in python using Keras (Theano backend): ``` model0 = Sequential() #number of epochs to train for nb_epoch = 12...

Using Windows Authentication in ASP.NET

I'm trying to use Windows Authentication in my ASP.NET application. Whenever I try to view the app it sends me to a login page. How can I make it work without having to manually login via the browser?...

Alternative solution to HostingEnvironment.QueueBackgroundWorkItem in .NET Core

We are working with .NET Core Web Api, and looking for a lightweight solution to log requests with variable intensity into database, but don't want client's to wait for the saving process. Unfortunate...

Nuget Package ... does not exist in project ... Package ... Already exists in folder

I've been fighting with this error for several hours and can't come up with a solution that works. I have an ASP.Net API within a multi-project solution which has its references/dependencies improper...

Using ASP.NET Core's ConfigurationBuilder in a Test Project

I want to use the `IHostingEnvironment` and `ConfigurationBuilder` in my functional test project, so that depending on the environment the functional tests run using a different set of configuration. ...

Web Service template missing from Visual Studio 2015 Professional

I've been tasked with creating a custom web service for a client solution. I've recently installed Visual Studio Pro 2015 and I can't seem to find the template for an .asmx Web Service. I remember it ...

Why use async with QueueBackgroundWorkItem?

What is the benefit of using `async` with the ASP.NET `QueueBackgroundWorkItem` method? ``` HostingEnvironment.QueueBackgroundWorkItem(async cancellationToken => { var result = await LongRunningM...

How to get response from S3 getObject in Node.js?

In a Node.js project I am attempting to get data back from S3. When I use `getSignedURL`, everything works: ``` aws.getSignedUrl('getObject', params, function(err, url){ console.log(url); });...

How can I generate a self-signed cert without using obsolete BouncyCastle 1.7.0 code?

I have the following code which generates a nice self-signed cert, works great, but I'd like to update to the latest BouncyCastle (1.8.1.0) and I'm getting warnings about obsolete usage: ``` var pers...

29 Apr at 15:21