text
stringlengths
15
59.8k
meta
dict
Q: How will I make this sequence correct in using c program I want to print a sequence of 1 4 9 16 25...n by inputting any number which is equal to the number of terms I want as an output. For example: if I input 4, it should print 1 4 9 16 but I can't seem to get the result I want using this program I have made. The r...
{ "language": "en", "url": "https://stackoverflow.com/questions/67708282", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Ambiguous reference error while compiling I have an Arrays class which contains several utility methods. The two methods in question are: @SafeVarargs public static <T> int indexOf(T needle, T ... haystack) { for (int i = 0; i < haystack.length; i++) { if (needle == null?haystack[i] == null:needle.equals...
{ "language": "en", "url": "https://stackoverflow.com/questions/35756235", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Make javascript run onclick instead of pageload I have the the following script that runs when the page is loaded: <script language="JavaScript"> j=parseInt(Math.random()*ranobjList.length); j=(isNaN(j))?0:j; document.write(unescape(ranobjList[j])); </script> How can I execute it when a button is cl...
{ "language": "en", "url": "https://stackoverflow.com/questions/14675302", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-3" }
Q: Refer to outer column in inner query Where clause I have two tables Employee and Departament in relation that is shown bellow. For each departament I want to get the fifth best paid employee. How the query should look like if we have for example MySQL? I trying to do something like this but it doesn’t see d.id colu...
{ "language": "en", "url": "https://stackoverflow.com/questions/28880245", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: drag and drop feature don't work properly I'm making a little utility for dragging and dropping some images inside a table, the thing is that every works correctly until I drop the image inside the table, the image is dropped in a different position to the one had been chosen $(function () { $('td.soccer-fiel...
{ "language": "en", "url": "https://stackoverflow.com/questions/30678869", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Asyncio requests using multithreading I have a large list of companies and am calling a REST API to get daily stock price for each company. Details are stored in a PostgreSQL database. The core function looks as follows: async def get_data_asynchronous(): conn = await asyncpg.connect(**DBConn) path = 'path' source...
{ "language": "en", "url": "https://stackoverflow.com/questions/60514129", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Return max value of each row of a group of columns I have a table of over 10,000 rows and over 400 columns. For columns containing at least the string 'xyz', I need to find the max value of each row (within these 'xyz' columns), and create 2 new columns. The 1st new column would contain the max value of each row of...
{ "language": "en", "url": "https://stackoverflow.com/questions/30181096", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to get token expiration with `jsonwebtoken` using typescript I'm using jsonwebtoken to decode a token, and I'm trying to get the expiration date. Typescript is throwing errors regarding the exp property, and I'm not quite sure how to solve them: import jwt from 'jsonwebtoken' const tokenBase64 = 'ey...' /* some...
{ "language": "en", "url": "https://stackoverflow.com/questions/47508424", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "12" }
Q: LValue required - Reason and solution for my first program I am doing my 1st year engineering. I am beginner to programming. I have program where I get the error - LValue required on the lines - 30,31 and 32 (marked in the code below). What is the reason for the error? #include<stdio.h> #include<conio.h> struct empl...
{ "language": "en", "url": "https://stackoverflow.com/questions/20219612", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: What information can I get from the android browser JavaScript? I know I can get screen width/height in a browser, can I get any other information about the device? Device name, OS, carrier, etc? A: It seems as though the only additional resources you're provided with have to do with screen density and resolution:...
{ "language": "en", "url": "https://stackoverflow.com/questions/4851986", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: NOT IN in Hive QL I'm converting a SQL Server stored procedure to HiveQL. How can I convert something like: SELECT * FROM table1 WHERE id NOT IN (7,6,5,4,2,12) A: NOT IN is now supported in Hive. See https://cwiki.apache.org/confluence/display/Hive/LanguageManual+UDF. A: Try this: SELECT * FROM table1 WHERE NOT...
{ "language": "en", "url": "https://stackoverflow.com/questions/14224335", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Are `System.MulticastDelegate`'s thread-safe? I'm looking for someone that might know more about this, my gut tells me that the answer is "no, it is not thread-safe" but I want to be sure. In order to illustrate my question, I have provided some context with this class public class MyContext { private readonly o...
{ "language": "en", "url": "https://stackoverflow.com/questions/48683134", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: The output shows zero, variable doesn't store the value The main class: package tdm; import java.util.Scanner; /** * * @author abbas */ public class TDM { public static void main(String[] args) { Scanner input = new Scanner(System.in); System.out.println("** WHAT DO YOU WANT TO FIND? **"); ...
{ "language": "en", "url": "https://stackoverflow.com/questions/41211534", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-1" }
Q: How to add button (onclick event) on tabs but not switch the panes - semantic UI I want to add a button on top of list of tabs configured with semantic UI. Currently I have 2 tabs which can switch to panes when they are selected and I have third tab - I don't want it to switch when user click on it but rather dispat...
{ "language": "en", "url": "https://stackoverflow.com/questions/74439945", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Problems with httpclient and selfsigned certificates I am sure this has been discussed in this group, but I couldn't find that thread, so bear with it, or if possible merge it with the original. I am using httpclient for my android app and I have a local site which has a few https pages. Since default httpclient doe...
{ "language": "en", "url": "https://stackoverflow.com/questions/3117896", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: How do I create an instance of a class from the child of a Mirror object in Swift I am trying to understand why I am unable to create an instance of a class using a mirror in Swift. In the playground, everything seems fine until the very last line of code below. So, here's the first example with the use of type(of:...
{ "language": "en", "url": "https://stackoverflow.com/questions/46551253", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to create element and set custom attribute to map a simple type class property @XmlRootElement(name="flowPane") public class Image implements Serializable { public String name; public String description; } Bound to <flowPane> <label text="name"/> <label text="description"/> </flowPane> Tried...
{ "language": "en", "url": "https://stackoverflow.com/questions/26182517", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Cannot run web app published with dnx I have an app based on the preview template of ASP.NET 5 RC1 final. I publish the app by running dnu publish --no-source --runtime active --configuration Release The resulting package contains the runtime "dnx-clr-win-x64.1.0.0-rc1-final". When I copy the package to another Wi...
{ "language": "en", "url": "https://stackoverflow.com/questions/33807582", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: React Componet - Element | undefined Implementing an Ionic Modal as a React Component I got this message: Type '({ onClose, tipo }: PropsWithChildren<{ onClose: any; tipo: number; }>) => Element | undefined' is not assignable to type 'FC<{ onClose: any; tipo: number; }>'. Type 'Element | undefined' is not assigna...
{ "language": "en", "url": "https://stackoverflow.com/questions/64920593", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Launched application settings but updating app permission crashing the app I have launched application settings using UIApplication.shared.open(URL(string: UIApplicationOpenSettingsURLString)!, options: [:], completionHandler: nil) I am using this to enable camera when the user has denied this once. In settings app...
{ "language": "en", "url": "https://stackoverflow.com/questions/44115930", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Postgres convert PATH type to ARRAY Is there any way to convert Postgres PATH type to an ARRAY in order to have index access to it's points? A: There is no way to do that with PostgreSQL alone - you'd have to write your own C function. With the PostGIS extension, you can cast the path to geometry and perform the op...
{ "language": "en", "url": "https://stackoverflow.com/questions/60389921", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: onCreate Intent Strait to URL without seeing a User Interface Ok, so I am new to Developing any kinds of Apps and have limited programming experience but I am trying to show my team a basic android app that skips strait to a website. I figured out the onCreate and using Intent. At this point I am trying to skip the ...
{ "language": "en", "url": "https://stackoverflow.com/questions/44863002", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: App / iOS crashes with “Terminating in response to backboardd's termination” I have an app which is crashing with Terminating in response to backboardd's termination Here the app crashes and even the Springboard. You can see the Apple logo for a short time and it seems that the device is rebooting. This is taken f...
{ "language": "en", "url": "https://stackoverflow.com/questions/32053817", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Post form to void controller action without getting redirected afterwards This is my view from which I'm posting the form: @using (Html.BeginForm("Register", "Account", FormMethod.Post, new { id="frmRegister", @class = "form-horizontal", role = "form" })) { @Html.AntiForgeryToken() @Html.ValidationSummary(""...
{ "language": "en", "url": "https://stackoverflow.com/questions/34252185", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: strategy pattern implementation with differing return classes I have a MessageProcessor class which processes xml messages of different types. A switch statement (C#) based on the message type calls the appropriate method to parse the xml and extract the data required for the type of message. I would rather have a ...
{ "language": "en", "url": "https://stackoverflow.com/questions/1985289", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How to load MobileNet weights with an input tensor in Keras I'm trying to apply transfer learning to MNIST using MobileNet weights in Keras. Keras documentation to use MobileNet https://keras.io/applications/#mobilenet Mobilenet accepts 224x224x3 as input but MNIST is 28x28x1. I'm creating a Lambda layer which can c...
{ "language": "en", "url": "https://stackoverflow.com/questions/47862788", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Segue using didSelectRowAtIndexPath I have a Master-Detail VC setup for a Core Data project. If the searchBar is active, one set of results is displayed, if it's not active, the objects from the fetchedResultsController displays in the MasterVC. I had been trying to segue using prepareForSegue, but I my instructor s...
{ "language": "en", "url": "https://stackoverflow.com/questions/28797044", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Getting InvalidConnectionAttributeException when trying to do a Database Connection I am getting InvalidConnectionAttributeException when trying to obtain a database connection. import java.sql.*; public class JdbcTest { public static void main (String[] args) throws SQLException { Con...
{ "language": "en", "url": "https://stackoverflow.com/questions/55994808", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Cache OAuth2 tokens in SpringBoot application? I am implementing a Spring Boot application, in which the methods are calling third party REST endpoints. This REST API is accessible after OAuth2 authentication. That is why I retrieve tokens from the third party (various users can use my application and respectfully c...
{ "language": "en", "url": "https://stackoverflow.com/questions/58119997", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "8" }
Q: didSelectRowAtIndexPath when is it being called So I am trying to make an app where you click a cell in a list of cells on the uitableview and it opens a cooresponding PDF file. To do this i want to pass the title of the cell in between to seperate classes. I have one class called "IndianaSpecificLawsView" that mana...
{ "language": "en", "url": "https://stackoverflow.com/questions/21960552", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-1" }
Q: Populate each value from a text file into a text box in a html using selenium My Requirement is as below: I have a web application which has Client search page(html). I have a list of Client numbers in a file. I want to pass first Client number from the file into a text box in the web url and click on submit button ...
{ "language": "en", "url": "https://stackoverflow.com/questions/65640165", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: passport-jwt token verification strategy never called I want to use passport-jwt to create my own strategy. According to several tutorial, i tried the following : // auth.js const passport = require("passport"); const passportJWT = require("passport-jwt"); const _ = require("lodash"); const users = require("./users....
{ "language": "en", "url": "https://stackoverflow.com/questions/47080576", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Vuejs v-for remove element I have code like : <div id="files"> <div v-for="(file, key) in data.files" v-bind:id="key"> @{{ file }} <span v-on:click="removeFile(key)"> <button>X</button> </span> <button v-on:click="addFiles()">Add Files</button> </div> </div> File js methods: { removeF...
{ "language": "en", "url": "https://stackoverflow.com/questions/50808837", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: jq validation get all errors For example I have form with 'firstname' field. I added two rules to this field (number, required). But when I submit form I see just one error. How I can see list of errors ('This field is required.' and 'Please enter a valid number.') ? .error { font: normal 10px arial; padding: 3px...
{ "language": "en", "url": "https://stackoverflow.com/questions/53695354", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: 502 BAD Gateway | ingress nginx with cert-manager I am using nginx ingress v1.1.3 in azure AKS v1.21. My traffic is getting terminated at nginx ingress for all other domains and it is working as expected. Recently I added cert-manager to manage certificate, but when implemented i am getting 502 for this particular i...
{ "language": "en", "url": "https://stackoverflow.com/questions/72149182", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: ViGEm.NET namespace missing when using Unity? [this question has the unity3d tag and I can't change it to unity2d] I was trying to use ViGEm using this tutorial to help me. But when I was writing the code, a red underline appeared on using Nefarius.ViGEm.Client; It said: The type or namespace 'Nefarius' could not be...
{ "language": "en", "url": "https://stackoverflow.com/questions/64923193", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: xml get width and set to android:height <LinearLayout android:layout_width="match_parent" android:layout_height=" " android:orientation="vertical" > Here's the thing, lets say i have this LinearLayout that has a width of match_parent, so the width of the LinearLayout depends on the width of the device. What i do...
{ "language": "en", "url": "https://stackoverflow.com/questions/20438705", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Failed to run test cases : cannot test target on simulator Cannot test target “FrameworkToolKitTests” on “iPhone 13 Pro Max” architectures: x86_64 Domain: XCTHTestRunSpecificationErrorDomain Code: 2 Using Xcode13.2.1 / testing framework code ,but testing not started Note: set (Enable testability : true )
{ "language": "en", "url": "https://stackoverflow.com/questions/74122033", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: React Native code stopped working all of a sudden I am dealing with a very strange problem. My React Native code was working fine till yesterday. I was trying to import FB data (User ID, Profile Pic etc) and was successfully able to see the FB User ID on my app till yesterday. All of a sudden I can't see it anymore....
{ "language": "en", "url": "https://stackoverflow.com/questions/65085103", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Xcode: Impossible to use c++ with Scenekit? I'm a beginner with Xcode... I'm trying to use openCV c++ with Scenekit=> to make an AR scene. Well, I was too optimistic. 1/I started to use the default XCode template for game.=> works! 2/openCV without scenekit=> works 3/ mixing... I imported some c++ headers in the gam...
{ "language": "en", "url": "https://stackoverflow.com/questions/29097946", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-1" }
Q: Login to Dropbox with vbscript I found a script on here to login to a forum that someone made and I edited it to login to Dropbox, but it still isn't working for me. I am looking for the script to uncheck the "remember me" checkbox and login to Dropbox from a vbs file that I execute on brand new machines. Here is wh...
{ "language": "en", "url": "https://stackoverflow.com/questions/37191755", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Reverse button click event with jquery I created a button that allows adding a geojson file to my map once we click on it. However, I would like to be able to have a hide/show option when pressing on the button. I mean when I click on it I would like my geojson to appear on my map and once a click a second time I wo...
{ "language": "en", "url": "https://stackoverflow.com/questions/70511764", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: WCF CallBack implementation Im having hard time to understand the advantages of callback on the basic way of making our client to be a service too and our service to be a client too. A: I can give you one big advantage. We have an application that involves a client (WPF) and a Windows service. Normally the client c...
{ "language": "en", "url": "https://stackoverflow.com/questions/10367648", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-6" }
Q: How to split the row in apache POI header I am trying to create table ind Microsoft Word using apache poi. But I am not being able to generate the header attached for the table. Any suggestions, i can create the attached header using apache poi? I am able to created the entire table but the last 2 columns which are...
{ "language": "en", "url": "https://stackoverflow.com/questions/58510514", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Split string to maximum length and append the rest to the last array item Is there a way for me to split a string into an array and limit to x and if there are more parts than the limit append to the last array item? So, for example I have 'Billy Bob Joe'.split(' ', 2) // Outputs ["Billy", "Bob"] I would like to ou...
{ "language": "en", "url": "https://stackoverflow.com/questions/44914080", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Modify every two largest elements of matrix rows and columns In python, I have a matrix and I want to find the two largest elements in every row and every column and change their values to 1 (seperately, I mean get two matrices where one of them modified the rows and the other modified the cols). The main goal is to...
{ "language": "en", "url": "https://stackoverflow.com/questions/41661362", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: Scroll Carousel, Default Tab Controller & GridView as one in flutter I have a design like this. What I want is that as I scroll up the GridView the Carousel scrolls up and the tab controller stays at the top fixed. All of this should be done in one scroll. I have done this before with custom scroll and sliver GridV...
{ "language": "en", "url": "https://stackoverflow.com/questions/63096568", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Need some help writing an EMPTY_OR macro I'm trying to code a macro called EMPTY_OR, which will return the first argument, but if it's empty, it will return the second one. Here's what I have so far: #include <iostream> #define EMPTY_OR(x, y) ( (sizeof(#x) > sizeof("")) ? (x) : (y) ) #define TEST(x, y) EMPTY_OR(y,...
{ "language": "en", "url": "https://stackoverflow.com/questions/23043371", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Collapsing columns in a table without jquery by click and by url for our intranet i've to do a large table with lots of columns. As there are many columns, i want to be able to hide some "blocks" of columns for better overview. The columns have two headings, one as kind of grouping for the "Progress step" and one un...
{ "language": "en", "url": "https://stackoverflow.com/questions/71926527", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-2" }
Q: Using foldl to calculate the product sum Basically, I wish to calculate a list with the algorithm as below: myList = [a1, a2, a3, ... a8] -- all elements are Int result = a[n] * n (where n is index starting from 0) result = a1*0 + a2*1 + a3*2 .... + a8*7 The below code works. prodSum xs = helper 0 xs where helpe...
{ "language": "en", "url": "https://stackoverflow.com/questions/72500121", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to replace part of tensorflow codes with a saved model I was wondering if someone can show me how to replace part of a big model with an (already) saved small model in Tensorflow. Precisely, what I want is, in the below, to make the f(x) with y=g(x) in part. The y=g(x) is the already trained, saved model, and I ...
{ "language": "en", "url": "https://stackoverflow.com/questions/48087828", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Setting properties transport and path for socket.io I'm trying to create the socket connection with the backend over the socket.io library. Thing is - I need to turn off the long-polling option and set the custom path. But I can't set them both because always work only one option. So, if I try this way, I'm setting ...
{ "language": "en", "url": "https://stackoverflow.com/questions/46796141", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Uppercase the names of multiple files in a directory in Python I'm working on a small project that requires that I use Python to uppercase all the names of files in a certain directory "ex: input: Brandy.jpg , output: BRANDY.jpg". The thing is I've never done on multiple files before, what I've done was the followin...
{ "language": "en", "url": "https://stackoverflow.com/questions/72037049", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-1" }
Q: How to check if a particular word from a string list contains in a string, but it should not be between any other words? I need to check if any string from a string list matches wholly (whole word search) within the input string i.e. it should not match the word in between characters. e.g. check the code below: Stri...
{ "language": "en", "url": "https://stackoverflow.com/questions/64184827", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Writing Long Functions With a "data" Argument I'm aware of how to write short functions using a data argument (How to handle "data" argument in a function?) - you can just copy and paste the body of the function and use an if-else statement to run the function depending on whether or not an argument is provided for ...
{ "language": "en", "url": "https://stackoverflow.com/questions/55896203", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How to monitor growth of On Premise Azure Devops Server We have our on-premise Azure DevOps Server that is growing quite fast. The database files (SQL Server 14) were about 130 GB. In less than a month are now 160 GB. There's an agent monitor (maybe an Azure DevOps extension?) to log mostly Azure DevOps operations t...
{ "language": "en", "url": "https://stackoverflow.com/questions/71438249", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Global access vs. local variables I have two objects that I will be mainly use inside of single class. I will initialize them at the beginning and use them throughout the life of the program. Now, my question is that if I should just create them as global variables and access them anywhere in the code (in side of ...
{ "language": "en", "url": "https://stackoverflow.com/questions/2508797", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "5" }
Q: How to create this custom ANN using tensorflow? I am trying to create this custom ANN using tensorflow. Here is image of the toy network and code. import tensorflow as tf import numpy as np in = np.array([1, 2, 3, 4], , dtype="float32") y_true = np.array([10, 11], , dtype="float32") # w is vector of weights # y_...
{ "language": "en", "url": "https://stackoverflow.com/questions/69527333", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Member turns to undefined I've developed a jQuery plugin which has default options: $.fn.incromentor.defaults = { max : 65355, min : 0 }; In the initialization of the plugin, I merge the user options with plugin default options using $.extend function init( $elm, options ) { this.$element = $elm; this...
{ "language": "en", "url": "https://stackoverflow.com/questions/11376784", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: @volatile usage unclear - sending an object with a `var` to another thread I am not sure I use @volatile correctly here. I have a buffer, like this: final class BufD(val buf: Array[Double], @volatile var size: Int) Which is sent between processes, whereby it might cross thread boundaries. The sender may update the ...
{ "language": "en", "url": "https://stackoverflow.com/questions/37305415", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "7" }
Q: why are drawables colored in black on some mobile phones? In my application I have got a few drawables and I give the user the possibilty to change the backgroundcolor with sharedpreferences. The problem is, that on some mobile phones the drawables are colored in black even if no sharedpreferences are set. The probl...
{ "language": "en", "url": "https://stackoverflow.com/questions/25126200", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: PrototypeJS not removing select element Given the following HTML, I'm trying to remove all form elements. The problem I'm encountering is that the select element is not being removed, but rather the first option in it is being removed each time the remove code is called. See http://jsfiddle.net/b8FfT/ HTML <fieldse...
{ "language": "en", "url": "https://stackoverflow.com/questions/19684961", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: C# Encrypt string with public RSA-1280 hex key I've been trying to encrypt a password with a public RSA key that is sent to me by the server. var csp = new CspParameters(1, "Microsoft Strong Cryptographic Provider"); RSACryptoServiceProvider RSA = new RSACryptoServiceProvider(1280, csp); byte[] key = ByteUtils.HexTo...
{ "language": "en", "url": "https://stackoverflow.com/questions/7360193", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Xamarin.Forms Android I'm developing a cross platform mobile application using Xamarin and Visual Studio 2013. I'm using Portable Class Libraries and I'm writing my code in the PCL project. Whenever I try to debug my app on the virtual android emulator I get this exception: Java.Lang.ClassNotFoundException: android...
{ "language": "en", "url": "https://stackoverflow.com/questions/25727471", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Beginner not sure how to join lists while scraping Hello I am trying to scrape www.allocine.fr for the latest movies I made the following script: # -*- coding: utf-8 -*- import urllib import re page = ["?page=1", "?page=2", "?page=3"] i=0 while i<len(page): url = "http://www.allocine.fr/film/aucinema/" +page[i...
{ "language": "en", "url": "https://stackoverflow.com/questions/25626324", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Problem with kotlin receiver when converting from java I'm trying to convert a java class into a kotlin class @Override protected Context constructContext(long entityId, String author, String changesSetId) { Context context = constructDefaultContext(author, changesSetId); try (Connection con...
{ "language": "en", "url": "https://stackoverflow.com/questions/66358023", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Qt Jambi (Qt4Dotnet): distinguishing signal emitters in a slot I'm newb to Qt and got stuck in a signal/slot mechanism. I have a toolbar with a number of tool buttons, each associated with some widget. The task is to show appropriate widget when tool button is clicked. I want to write a single slot that will handle ...
{ "language": "en", "url": "https://stackoverflow.com/questions/1139216", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How to calculate minimum unixtimestamp value using sparksql? completion time | unixtimestamp | user| 0.07 |1529094938000 |user3| 0.16 |1529094944000 |user2| 0.27 |1529094947000 |user1| 0.08 |1529094950000 |user2| 0.24 |1529094953000 |user1| 0.10 ...
{ "language": "en", "url": "https://stackoverflow.com/questions/51722975", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Micronaut multiple JDBC templates not working I am trying to write a micronaut function which is deploying as AWS Lambda. With my micronaut function, I need to connect to multiple databases and get the data and put details into AWS SQS. In this regard, I am trying to use JDBC template approach to get data from diff...
{ "language": "en", "url": "https://stackoverflow.com/questions/60256665", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Using & validating RTF input after using FILTER_SANITIZE_FULL_SPECIAL_CHARS I am trying to validate a rich text input provided by the TinyMCE editor. I am very aware of leaving myself open to XSS etc and want to get this right. I am sanising the POST data prior to doing anything with it with the following code: //sa...
{ "language": "en", "url": "https://stackoverflow.com/questions/61695468", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Matlab mcc Warning "Adding path ... to Compiler path instance" I'm compiling my matlab .m functions (and mex files) to run as a standalone program on a Linux server. In the end, I manage to compile all files and even run them, although in the process I do get some warnings: Warning: Adding path "input_folder1" to Co...
{ "language": "en", "url": "https://stackoverflow.com/questions/22475129", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "6" }
Q: Drawables Ldpi Mdpi Hdpi Xhdpi Can Anyone tell the ratios of ldpi, mpdi, hdpi, and xhdpi? and also how can I tell if the phone/ tablet is in ldpi mdpi hdpi and xhdpi? Tnx in advance A: Approximately 3:4:6:8 for the ldpi mdpi hdpi and xhdpi ratios.
{ "language": "en", "url": "https://stackoverflow.com/questions/24587100", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-5" }
Q: In Rspec Capybara integration test ,Controllers not maintaining session after login/signup, getting current_user nil I have a test case where after registration devise signup(resource_name, resource) method is called and a redirect_url is sent back to front end , which in turns load the requested page by window.loca...
{ "language": "en", "url": "https://stackoverflow.com/questions/47299834", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Generating Random Number AVR without seed I writing an application in AVR Studio 4 which generates random numbers and outputs them on a seven segment display. At the moment i am using a seed, the seed value then gets randomized and the value output. This method obviously produces the same random number sequence (and...
{ "language": "en", "url": "https://stackoverflow.com/questions/29201603", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: All permutations with repetition using scala I am looking for the scala way to give all permutations without repetitions. I know there are some postings on this site already but they seem to have a slightly different problem. I am searching for all permutations with repetitions. For example: combine(List('A','C','G'...
{ "language": "en", "url": "https://stackoverflow.com/questions/7474709", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "9" }
Q: Lua and Visual C++ I have a simple question. When I open VC++, create an "Empty Project," insert the Lua 5.2.0 source code, then compile, I get no errors. However, when I do this except select "Windows Forms Application" at the beginning, I get a whole bunch of errors. What may be causing this? EDIT: The errors are...
{ "language": "en", "url": "https://stackoverflow.com/questions/9439262", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: darcs appending extra directory separator I am having a problem using darcs getover ssh. I think the failure is because of something wrong in the path to the repository, but I cannot figure out how to correct. The error message reads: darcs failed: Not a repository: britt@brittoffice.uwaterloo.ca:/home/britt/manusc...
{ "language": "en", "url": "https://stackoverflow.com/questions/19802455", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: #1062 - Duplicate entry 'default-0-payment/paypal_standard/active' for key 'UNQ_CORE_CONFIG_DATA_SCOPE_SCOPE_ID_PATH I have this problem so i followed answer in that link, it didt worked for me. so i followed comment of @Mukesh Chapagain , INSERT INTO core_config_data (config_id ,scope ,scope_id ,path ,value) VALUES...
{ "language": "en", "url": "https://stackoverflow.com/questions/38315067", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to persist the time and score using shared preferences I having developing simple application, which has just like game. When I have finished game the gave over page display, which as time and score. Now if i want to play that game again and again. How to store that previous all time and score and current finish...
{ "language": "en", "url": "https://stackoverflow.com/questions/8666116", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: CFLOOP Duplication I have a drop down list that is generated by two loops. The inner loop generates a series of numbers ie from 0 to 23. The outer loop, is a query loop that selects the correct value from the 23 numbers based on the values stored in my database. My issue here is that those two loops conflict that re...
{ "language": "en", "url": "https://stackoverflow.com/questions/10095496", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Microsoft Azure Directory oAuth redirect_uri not accepting state query parameter I'm trying to implement the oAuth flow to sign in with Microsoft. I have the following endpoints: https://login.microsoftonline.com/common/oauth2/v2.0/authorize https://login.microsoftonline.com/common/oauth2/v2.0/token My flow is like ...
{ "language": "en", "url": "https://stackoverflow.com/questions/63316748", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: create a set of cumulative intersection counts I want to count the intersection of var1[i] and union(var2[1],...,var2[i]). Using this data var1 <- list('2003' = 1:3, '2004' = c(4:3), '2005' = c(6,4,1), '2006' = 1:4 ) var2 <- list('2003' = 1:3, '2004' = c(4:5), '2005' = c(2,3,6), '2006' = 2:3 ) I would like to popul...
{ "language": "en", "url": "https://stackoverflow.com/questions/12209276", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: remove Cookie using jquery not working I have two cookies in my JS file and I want to remove them. I have tried the code below but it is not working $.removeCookie('filter', { path: '/Home/' }); $.removeCookie('Pfilter', { path: '/Home/' }); I have also tried the below for null cookies, but this is also not worki...
{ "language": "en", "url": "https://stackoverflow.com/questions/18486165", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "21" }
Q: Could not convert parameter `tx` between node and runtime: Could not decode `Call::Assets.0`:Could not decode Execution failed: ApiError("Could not convert parameter `tx` between node and runtime: Could not decode `Call::Assets.0`:\n\tCould not decode `Call::create.3`:\n\t\tNot enough data to fill buffer\n") Runt...
{ "language": "en", "url": "https://stackoverflow.com/questions/69682136", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-3" }
Q: folium:: make GeoJson search marker transparent I have a basic folium heatmap that shows locations as CircleMarker and a HeatMap layer on top as displayed below. I wanted to add search functionality in my map so I converted my pandas dataframe into a GeoJson format so that I can pass that. class folium.plugins.Sea...
{ "language": "en", "url": "https://stackoverflow.com/questions/55312766", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Forcing error in TypeScript compile with void return With the following code: function foo() : void { // do something } var f = foo(); // why no error here? This does not produce a compiler warning/error even though the foo function has been declared to not return anything. Another case that I'd like to preve...
{ "language": "en", "url": "https://stackoverflow.com/questions/24308842", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Dynamic build a table from json data in angular2 I can't wrap my head around a looping system I need to make to build up a table from json data. This is what I've got so far (tried some other stuff but I think this illustrates it the best way). Looping through the headers works fine, it's just the cells I can't get ...
{ "language": "en", "url": "https://stackoverflow.com/questions/54762274", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Dynamically add new field with same key name in MongoDB Im trying to create a list on one of my collections in a dynamic way, here is an example. var user = mongoose.Schema({ "NAME": String, "LAST": String, "EMAIL": String, "TasksUploaded": {} }) And what I want to do in mongoose is update the user with the tasks h...
{ "language": "en", "url": "https://stackoverflow.com/questions/41387686", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Overriding a forms OnPaint method in component class Im looking to override the OnPaint method of the parent form of my component.. However i face 2 errors while doing this, the first is assigning the parent forms event handler * *No overload for "OnPaint" matches delegate "PaintEventHandler" *Member from "Regio...
{ "language": "en", "url": "https://stackoverflow.com/questions/45839096", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Values of array after cudaMemcpy I'd like to know if, when i'm calling cudaMemcpy(...) to get memory on the GPU, also the values inside the array are copied or not. I will explain better: I'm copying the values from one array to another and then i call cudaMalloc and cudaMemcpy. // Copying values of the arrays for(...
{ "language": "en", "url": "https://stackoverflow.com/questions/9928812", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: How do I locate data in a database with vague column names? In our database we have a number of tables that have non-descriptive columns names e.g. (Attribute1, Attribute2....Attribute60 etc). What I am wanting to know is if given a particular piece of information e.g. I know that a Job Code could be "123456", but ...
{ "language": "en", "url": "https://stackoverflow.com/questions/15285713", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: how to upload to files to amazon EC2 I am trying to upload files to an amazon EC2 from android. however whenever i go to upload the files I get a Unexpected response code 500 error. From what I uderstand this is because the user doesnt have the correct permissions to upload files to the database? I know that the pro...
{ "language": "en", "url": "https://stackoverflow.com/questions/42382461", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Merge fields laravel collections I have two Laravel collections. Mi first collection called $custom_product: Collection {#313 ▼ #items: array:1 [▼ 0 => array:1 [▼ "custom_description" => "insert description here" ] ] } And I have my other collection called $api_product: Collection {#311 ▼ #items...
{ "language": "en", "url": "https://stackoverflow.com/questions/41415324", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Access parent object of Button in click event in UWP application with C# This is for a UWP application for raspberry pi (c#). I have a button as a public member of a class written by me. Since this is a member of class. Whenever an object of this class is created, it needs to have a Click event. I need to have the c...
{ "language": "en", "url": "https://stackoverflow.com/questions/65035416", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: JQuery Mobile clone page I having trouble cloning a page of jqm. Here is an example: http://jsfiddle.net/QZKBw/ as you can see, the cloning and modifing the page is not the problem: var newPage = $('#page-1').clone(); newPage.prop('id', 'page-2'); newPage.find('#header-1') .prop('id', 'header-2')...
{ "language": "en", "url": "https://stackoverflow.com/questions/14923313", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Cannot acces a disposed object I'm trying to change some of my linq codes to sp but in one my functions which is private async Task getNodes() { List<TreeViewNode> nodes = new List<TreeViewNode>(); var activities = await _spConnections.GetActiveListBySpAsync(User.Identity.GetCookieUserCompId<int>()); //...
{ "language": "en", "url": "https://stackoverflow.com/questions/63243207", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Collecting custom Simple Analytics metadata in a Next.js app I am struggling to collect custom Simple Analytics metadata in my Next.js app. Looking at their docs, I can either set metadata on the window object (link) or add it via a callback function (link). My Next.js app looks as follows: _document.js import Docum...
{ "language": "en", "url": "https://stackoverflow.com/questions/75448951", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to manipulate rendered data table that uses a reactive expression? I'm quite new with using Shiny. The code below is actually part of an Rmarkdown file with Shiny coding in it. I have an issue in handling reactive expressions within Shiny. Basically after calling a reactive expression, I can render or plot the e...
{ "language": "en", "url": "https://stackoverflow.com/questions/44287545", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Adding another column to a numpy array I have two arrays of the following dimensions: a = (6,1) b = (6,4) I wish to add array (a) as additional column to array (c). Tried: c= np.column_stack([b,a]) and get an error due to mismatch of dimensions. A: Try: c = np.concatenate((b,a), axis=1) This assumes that a.sh...
{ "language": "en", "url": "https://stackoverflow.com/questions/40360469", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Parse html page source with libcurl and C How can I print the source of a webpage, specified in curl_easy_setopt, without html tags? So, printing only the text in the source? A: Curl/libcurl is just for fetching the HTML page. To extract information from it, you need other tools. The most general solution is to use...
{ "language": "en", "url": "https://stackoverflow.com/questions/2162201", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }