title
stringlengths
13
150
body
stringlengths
749
64.2k
label
int64
0
3
token_count
int64
1.02k
28.5k
How to make projections of selected attributes in mongoid?
<p>I have Coordinate model with many markers embedded_in User model. How to extract attributes without _ids so that on output display only each lng and lat?</p> <p>structure:</p> <pre><code>{ "_id" : ObjectId( "4e9f418f1e7bf20fbc000009" ), "name" : "test", "coordinates" : [ { "lng" : 16.86783310009764, ...
3
1,034
calling asp from an SVG click
<p>I'm building a soccer field application to help me with stats for my team. I've used SVG to create the field and place images on the field for each player position. The players are listed along the right side of the field as image buttons.</p> <p>When I click the SVG position image, I need a way to store the id of...
3
2,009
Fancybox Gallery: carousel view error on Multiple galleries
<p><code>enter code here</code># Problem with Fancybox Gallery # <em>Problem with Multiple galleries in the Carousel view</em></p> <blockquote> <p>My problem is! <br /> Category1 shows all images in the carousel instead of only Category1. <br /> For Category2 to Category5, everything display correctly. <br /> With All,...
3
7,310
__toString return name from another entity
<p>Let say I have 2 tables in my database : lesson and group. Group can have 1 lesson per year. </p> <p>Then I will have 2 entities, lesson entity :</p> <pre><code>&lt;?php namespace Sifo\AdminBundle\Entity; use Doctrine\ORM\Mapping as ORM; class Lesson { /** * @var integer */ private $id; /** ...
3
1,225
Grails using a get within a g:each
<p>I'll acknowledge right off that the title is probably not the right reference here so please let me know if I'm using the wrong phrase and I'll correct!</p> <p>Overview - I have an Form.gsp and corresponding _form.gsp, into which I feed a load of values from an SQL query, which includes the ID from another controll...
3
1,112
google maps infoWindow click event re-renders map-canvas in Meteor
<p>Hey Im trying to use google maps within my MeteorJS project to have google maps display on a map all customers, and then to display an infoWindow when you click on one of the markers.</p> <p>problem is anytime you click on the marker it re-renders the map from scratch, i know this has to do with the the reactivity ...
3
1,119
parsing xml data with vb.net
<p>I am currently attempting to parse data with VB.net to populate some textboxes selecting by childname "eResponse.01", 02, 03 etc however a namespace / schema location in the main tag seems to be tripping up the code.</p> <pre><code> Dim xmlDoc As New XmlDocument() xmlDoc.Load("C:\Users\james\Desktop\NEMSIS\E...
3
1,601
AWS Image upload data to S3 from form is corrupt
<p>I am using multer in a Lambda function to upload an image through an API POST request I am building, this is part of a form on my website.</p> <p>This is the console log from cloud watch:</p> <pre><code>{ fieldname: 'logo_image', originalname: '8824.png', encoding: '7bit', mimetype: 'image/png', destinatio...
3
1,422
Android navigationview with header set , onItemClick not working
<p>I'm developing an application (as my first one) and In this app I've declared my navigationView like this:</p> <pre><code>&lt;android.support.design.widget.NavigationView android:layout_width="wrap_content" android:layout_height="match_parent" android:id="@+id/navigation_drawer" android:layout_g...
3
1,827
Handling Button and EditText to Send an SMS
<p>I want to handle an EditText and a button in my listView to send an sms. So far, the phone Numbers are entered by the user. So, I have made an adapter as the following : </p> <pre><code>public class ListViewStudentWithDateAdapter extends ArrayAdapter&lt;ListViewStudentWithDate&gt; { private Context mContext; priva...
3
1,157
Make the Title row in grey background with Blue fonts after convert json to excel
<p>I have developed a json to csv file download function everything works fine but I'm not sure how to make the first row of the table which are &quot;Vehicle, Date, Location, Speed&quot; background color in lightgrey and font in blue and always expand the columns upon opening the file</p> <p>Here is the fiddle <a href...
3
1,191
Unable to install speech_recognition(pyaudio)
<p><em><strong>STEP BY STEP PROCCES of how i got the error</strong></em></p> <p>The command I ran:</p> <p><code>pip install SpeechRecognition</code></p> <p>Log:</p> <pre><code>WARNING: Ignoring invalid distribution -p (c:\python310\lib\site-packages) WARNING: Ignoring invalid distribution - (c:\python310\lib\site-packa...
3
3,325
Counting references in a self referenced table based on both the referring and referenced rows
<p>I am working on a table that stores two levels of tasks (let's call it <code>primary</code> and <code>secondary</code>), in the same table using self-referential foreign keys. Column <code>secondary_for</code> is a self-reference on <code>tasks.id</code> where as <code>user</code> is a reference to a different table...
3
1,041
Hamburger Menu on desktop website (with small size icon) for full width and height dropdown on toggle click (Bootstrap 4)
<p>I am having difficulty to make my hamburger menu to display a full width and height on toggle button click. I am trying to create a hamburger with small icons positioned left of the screen which when clicked displays a full width and height (transparent) and position the navitems horizontally. </p> <p>The image of ...
3
2,250
another box in menu bar html css
<p>i try to create box e.g link box.. so when i hover mouse on research then menu appears e.g about gjbssr,data collection services etc... but link always appear with this menu and i want when i hover mouse on about gjbssr then link box will be appear image <img src="https://i.stack.imgur.com/oN89R.png" alt="enter imag...
3
1,751
Using libusb-win32 to communicate with USB to DMX512 interface, can't find any endpoints
<p>I am trying to send raw data to a set lights from my computer through a USB to DMX512 interface using libusb-win32. So far everything seems to be working well, except for some reason the program doesn't recognize any endpoints on the adapter. Here is a snippet of my code:</p> <pre><code>// initialize usb_init(); us...
3
1,173
Error when calling insertionsort method and how to print an arraylist
<p>I have created a program which stores temperature(double) and day(string) in an arraylist, then uses the comparable interface and an insertion sort to sort the arraylist. Now all that i have left is calling the insertion sort method and print out the original order of the arraylist and the sorted order. However when...
3
1,151
Error: No Sequelize instance passed in Nodejs
<p>I'm having this problem when I try to start my application or run some route. I can't understand why. Can anyone help?</p> <p>The full error:</p> <pre><code>Error: No Sequelize instance passed at Function.init (D:\repo\lbr\node_modules\sequelize\dist\lib\model.js:1:13622) at initUser (D:\repo\lbr\db\models\U...
3
2,115
Error 401 when trying to download a file after using Google Picker API
<p>I have a react app that allows user to pipe in a particular Google Doc that we then analyze the content of. For step 1, picking the document, I'm using <a href="https://www.npmjs.com/package/react-google-picker" rel="nofollow noreferrer">this nifty npm package</a>, which also returns to me an &quot;OAuth token&quot;...
3
2,541
How can i get elements to stack on top of each other for mobile users without changing the view for desktop users
<p>As you can see in the screenshot, there is an image and then the title, price, options, add to cart button, countdown timer and description to the right. I'm happy with this but when I view this through a mobile browser, it doesn't look too appealing. How can I change my CSS/HTML so each of the elements next to the ...
3
4,273
System.OutOfMemoryExeption C#
<p>When I'm running my application and load a file(25MB) through it, everything runs just fine.</p> <p>But when I try loading a file(160MB) I get a <code>System.OutOfMemoryExeption</code>. Although I have been able to load the larger file at some point in time.</p> <p>Is there anyway to fix this? If so, any help woul...
3
12,915
How to fix - Object "Inputs2' not found. And get the final plot in R Shiny
<p>I am new to building apps in RStudio Shiny. I have checked everything in my following code and it seems to be working all the way up to plotting, however I can't get any plot and the server window gives an error: "Object 'Inputs2' not found." Any help will be appreciated with the code. And my final goal is to get th...
3
1,925
Assistance parsing with gson (google json)
<p>I have some JSON. With GSON, it always throws an error</p> <p>Exception in thread "main" java.lang.IllegalStateException: Not a JSON Object: </p> <pre><code>[["Rank","Team","Qual Avg","Auto","Container","Coopertition","Litter","Tote","Played"],[1,1730,126.3,160,488,160,137,318,10],[2,1806,96.799999999999997,20,516...
3
1,648
Reference not set to instance error
<p>This is my code, and when I run the project, there are no errors, but when it goes to my Dispense() event "An unhandled exception of type 'System.NullReferenceException' occurred" in the line ManDis = returnedMessage.Substring(8, 3)</p> <p>It is necessary to do a try..catch or something?</p> <p>Thanks!</p> <pre>...
3
2,996
Android app crashes when button is pressed after not having the app open for a while?
<p>I am making an app, and if I use it normally it works fine with no crashes. There is one activity with two fragments that are swapped, and one has two buttons on it. If the app isn't used for a while (hours) and the app is reopened, then if I press one of the buttons the app crashes. This only happens if I exited ou...
3
4,449
I'd like to create a progress bar
<p>I need to show the progress for my <code>todo list</code></p> <p>Here is the code for my progress bar</p> <pre><code>&lt;!-- todo list --&gt; &lt;div class="col-md-5"&gt; &lt;div class="panel panel-default panel-hovered mb20 todo" id="todoApp"&gt; &lt;div class="panel-heading"&gt; &...
3
2,787
How to pass multiple values to keras joined model
<p>I'm having two pre-trained models. Assume those are model_A and model_B. Here, the model_A is a CNN + LSTM network and model_B is a GCN. </p> <p>Model_A:</p> <p><a href="https://i.stack.imgur.com/Ty3KH.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/Ty3KH.png" alt="enter image description here">...
3
3,192
Favorites showing on all users, not the specific one a user favorites
<p>Attempting to make a favorites button, then when clicked will only show favorites for a specific user not show all favorites for all users. My OnClick is hitting my POST correctly, and on the backend when a user favorites a coffee shop it only shows against their profile not anyone else. So I think its just the wa...
3
1,308
Multiple draw requests dynamically iPhone
<p>I'm attempting to make guider/tip boxes for the iPhone as part of a tutorial framework i'm making. I've followed and combined two codes i've found here: (http://stackoverflow.com/questions/6049682/iphone-how-to-make-a-tip-balloon-programmatically/6052438#6052438 ) and another (cant find the link but pretty sure the ...
3
1,769
Unable to maintain previous value of variable into another variable in C?
<p>I have tried to make demo code of my actual code. I am having 2 gloabal variables prevValue and currentValue . After some time interval value of "currentValues" may get change (either x, y or z).</p> <p>My aim is to <strong>maintain value of "currentValue" variable from earlier stage(N-1) into "prevValue" variable ...
3
1,390
Why do I get multiple XHR requests when network is slow?
<p>When I execute an action (upload a post request) on my website from my home network (Slow, less than 1Mb/s upload), the Chrome dev tool shows several XHR requests :</p> <p><a href="https://i.stack.imgur.com/xvuNI.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/xvuNI.png" alt="enter image descripti...
3
1,727
get-winevent: Property Field filled with System.String[] after removing descriptional content parts
<p>I'm trying to filter event-logs, which works fine except for the message field within the query. The message field has a lot of descriptive text in it. I only want the first sentence of it, because this is the important one, the rest is garbage. </p> <p>Example content of a message-field:</p> <pre><code>An account...
3
1,570
C# User defined Array Size
<p>As seen below, I have:</p> <ol> <li><p>A class (<code>Viatura</code>) that creates a Vehicle.</p></li> <li><p>Another class (<code>ArrayViatura</code>) that creates an array of Vehicles and subsequent methods.</p></li> </ol> <p>In the form, I <strong>have</strong> to let the user define the <strong>size</strong> o...
3
5,145
Invalid characters and post-update-cmd error on composer update Laravel
<p>When I try to update any dependencies I get the error below:</p> <pre><code>1 - [ErrorException] Invalid characters passed for attempted conversion, these have been ignored 2 - Script php artisan optimize handling the post-update-cmd event returned with...
3
1,569
how to make only the function sleep instead of the entire program in kivy
<p>so like basically, sleep stops the entire script and this isnt good and I most likely dont want that, so any solutions to this? (it is for this boy right here):</p> <pre><code> def on_button_click(self): global started if started==False: started=True enemyname = self.ids.st...
3
1,996
How to get specific value from JSON and display it's elements on CollectionView?
<p>Is it possible to get specific elements from JSON and display it's other elements on collectionView?</p> <p><strong>Broader question:</strong> This is my JSON object:</p> <pre><code>{ "id": 1, "floor": 1, "full_name": "Ernst &amp; Young Audit LLC", "description": "Ernst &amp; Young («Эрнст энд Янг»...
3
1,265
Laravel 4 App Show White Screen/Page
<p><strong>Description</strong> </p> <p>I've not been working on Laravel 4 environment for about 2 years now. Now, I'm trying to help a friend out, and make some modification to the site. While trying to get the site up and running, I faced some errors. </p> <hr> <p><strong>Steps</strong> </p> <ul> <li>Clone the pr...
3
1,428
Windsor IoC DbContext
<p>I am trying to add Windsor Castle 3.3.0 IoC with my MVC 5 project dbcontext (EF 6) and have had a look at many articles, but I can't figure out how to do it and keep running into the problem of getting the following error:</p> <blockquote> <p>The operation cannot be completed because the DbContext has been dispos...
3
1,348
How to combine two dataframes and naturally sort on a column of mixed alphanumeric types?
<p>I have <a href="https://docs.google.com/spreadsheets/d/15OU7SwaxqW4vds3E2uN-exPiXOQg2bMJmrGcxIYalaI/edit?usp=sharing" rel="nofollow noreferrer">a dataframe <code>df1</code></a>:</p> <pre class="lang-py prettyprint-override"><code> QID Questions B Answer1 Answer2 Answer3 F G H I J 0 3 a 4.0 ...
3
1,681
need help in ATM Alloy
<p>I am trying to model that, ATM system which provides an available amount of money after authenticates that the card and pin are correct, otherwise, the amount of money is not provided. Also if the card is incorrect, it will be rejected if the pin is not correct , it will be rejected</p> <p>In the first model, ther...
3
1,316
Dragging in spark List does not work in Flex mobile app? Test case and screenshot attached
<p>I would like to reorder items of a List in a Flex mobile app by dragging them around with a finger.</p> <p>As a first step I have copied the example from Adobe document <a href="http://help.adobe.com/en_US/flex/using/WS2db454920e96a9e51e63e3d11c0bf69084-7cfd.html" rel="nofollow noreferrer">Using drag-and-drop with ...
3
1,062
@RequestMapping Couldn't find Jsp page
<p>I tried to build a small app in spring-boot, it's structure is given below. I am having a weird problem with @RequestMapping where it's able to find all the resources except one.</p> <p>Here is the <code>web.xml</code> file</p> <pre><code>&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?&gt; &lt;web-app v...
3
2,917
Rails Remote True Ajax ActionController::UnknownFormat
<p>I have a mini-update method in my model that only updates one field, set up in a chart (so I see the form for each row). It works properly, but want it to update using AJAX to be able to do multiple updates quickly without waiting for a full page reload.</p> <p>The cell looks like this:</p> <pre><code> &lt;t...
3
1,047
Write and read from URL in jQuery element filter
<p>I have got jQuery function (thanks to @CarstenLøvboAndersen again) for filtering elements. For example: If I check RED and BLUE then it filter only elements with both class RED and BLUE. When I click all, script uncheck all checkboxes and show all elements.</p> <p>I need to improve the function with the possibility ...
3
1,209
Laravel ajax post, not getting response, error or db insert
<p>I'm trying to make a POST ajax call that will take a form input value, pass it, through a route, to the contoller which will call an insert function. I've set my route, my insert function, my controller and my blade with the ajax call, but when I fill the input and hit the submit button, there is no response or erro...
3
1,179
Multi-processing in Python: Numpy + Vector Summation -> Huge Slowdown
<p>Please don't be discouraged by the long post. I try to present as much data as I can, and I really need help with the problem :S. I'll update daily if there are new tips or ideas</p> <h1>Problem:</h1> <p>I try to run a Python code on a two core machine in parallel with the help of parallel processes (to avoid GIL)...
3
7,426
Combine two modules into a single module for publishing
<p>I'd like to split up a module (<code>library</code>) in two modules (<code>lib-core</code>) and (<code>lib-extras</code>).<br> Currently, I'm publishing with artifact id <code>library</code>, and I want to keep this functionality as well. I also want to publish the two separate modules.</p> <p>For example:</p> <bl...
3
1,643
PHP SQL Injection - Executing and returing empty value
<p>I have an IOS application that executes a PHP Script but when i test in the browser and in IOS i get empty string returned from PHP script call:</p> <p>PHP Version is 5.2</p> <p>This is the url i am calling :</p> <p><a href="http://hugt.co.uk/checkUserVerification.php?Email=tp_redo_c@hotmail.com&amp;Password=ULLA...
3
2,895
Send multiple files using socket
<p>I'm trying to send multiple files from client to server using socket but when I click upload button it adds only one file and the second click adds the second. This is my code:</p> <p><strong>client</strong></p> <pre><code> void SendFile (String St, String Na) throws IOException{ Socket sock ...
3
2,055
iOS- Cannot get expected json results back
<p>I am trying to use google currency rest api to get USD->GBP convert result. something like this-> <a href="http://www.google.com/ig/calculator?hl=en&amp;q=100USD=?GBP" rel="nofollow">http://www.google.com/ig/calculator?hl=en&amp;q=100USD=?GBP</a></p> <p>the json is response is :<br> {lhs: "100 U.S. dollars",rhs: "6...
3
1,103
pandas dataframe count duplicates by group and date
<p>I have a dataframe with 3 columns:</p> <ul> <li><code>'Date'</code> unique for each row</li> <li><code>'Group'</code> group to which each row belongs</li> <li><code>'ID'</code> identifier for each row</li> </ul> <p>In the <code>'ID'</code> columns there are some duplicate values. I want to count the number of repeti...
3
2,080
How to verify mbedtls signature in node.js?
<p>I have seems working way how to verify the signature with mbedtls on ESP32. Now I need to verify the same signature with NodeJS but I had no success with it.</p> <p>mbedtls example:</p> <pre><code>#include &quot;mbedtls/base64.h&quot; #include &quot;mbedtls/pk.h&quot; #include &lt;string.h&gt; unsigned char hard_ba...
3
2,771
Exception Exception is not compatible with throws clause in SpringAMQPMessageSource.onMessage(Message, Channel) Axon
<p>I am working on Spring Boot + Axon Framework developing demo explain here: <a href="https://www.youtube.com/watch?v=Jp-rW-XOYzA&amp;list=PLgGXSWYM2FpOa_FTla-x5Wd10dpmgrRC4&amp;index=54" rel="nofollow noreferrer">https://www.youtube.com/watch?v=Jp-rW-XOYzA&amp;list=PLgGXSWYM2FpOa_FTla-x5Wd10dpmgrRC4&amp;index=54</a>....
3
1,902
How does one implement convolutional GRUs/LSTMs/RNNs in Pytorch?
<p>I want to have the standard LSTM/GRU/RNN set up but swap the linear function with a convolution. Is that possible to do in Pytorch in an clean and efficient manner?</p> <p>Ideally it still works with packing, varying sequence length etc.</p> <p>Small sample code of a trivial way to pass data through it would be su...
3
1,592
Elasticseach not using synonyms from synonym file
<p>I am new to elasticsearch so before downvoting or marking as duplicate, please read the question first.</p> <p>I am testing synonyms in elasticsearch (v 2.4.6) which I have installed on Ubuntu 16.04. I am giving synonyms through a file named <strong>synonym.txt</strong> which I have placed in <strong>config</strong...
3
1,545
connection is lost every hour or two hours
<p>I use this code in my website for MySQL connection class.But generally connection is lost every per hour or two hours.when this happened, MySQL connection class don't work and my website index page can not be displayed. I don't know the reason for that problem.</p> <pre><code>using System; using System.Collections.G...
3
2,693
CSS Design Issue in IE 9 & 8 when page is developed in asp.net
<p>I have a designed landing page in asp.net 4.0 i am using repeater control to generate Boxes.</p> <p>Issue is that it looks good in FF and Crome but design move up adds space under image and look smessy. it is pretty clear from the screen shot also</p> <pre><code> &lt;div id="bodyContainer" class="bodyContainer"...
3
13,855
How tot get back from numpy datetime array to datetime?
<p>tried to write a simple programme for get the most vacation between two dates. E.g. for 2021, if wednesday is public holiday, you could get 9 free days with taking 4 holidays.</p> <p>..everything okay, my idea was:</p> <p>create busdaycalender, start, end, arange it and count all free days in a bool array and return...
3
1,200
How can I parse Json which starts with "/" in android using volley?
<p>I am parsing json data from URl but it starts with "/". I have a data class which is a POJO class in the app. Here is my json file.</p> <pre><code>/{ "data": [ { "id": "1", "text": "Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut lab...
3
1,111
Using Semantic-UI stylized select element with jQuery Validation
<p>I have jQuery Validation setup for a two-step form, and the form is validating as expected with errors under each input and select menu from the first screen to the second screen with the submit button.</p> <p>However, when I enable the Semantic-UI Dropdown Module to style my select menus in the form, the select me...
3
3,626
MySQLI INSERT query is executed twice
<p>I have the following code:</p> <pre><code>// open the database connection require_once('php/db/connect.php'); // set a log file $logFile = 'log/php.log'; // set the error and the doCommit to false $error = false; $doCommit = false; // build the query $query = "SELECT name,gender,email,country FROM tmp_backer WHERE ...
3
1,629
importing 20k details in php using csv
<p>I'm trying to insert a csv file with at least 20k lines, and it prompts my browser to kill it self, I guess its taking up a lot of memory and its processing it really slow, I'm also doing this for export and still the same problem it takes too much time that the browser wanna kill it self. Do you have any suggestion...
3
5,892
Once page load , table content disappearing in IE 11
<p>I just created mvc 4 application to view table data set ,this is working fine in IE 9 , IE 10 , FireFox and Chrome .</p> <p>but in IE 11 once page load its disappearing its whole row content </p> <p>this is the view file </p> <pre><code>@model IEnumerable&lt;AFFEMS2_HEC.Models.tbl_hec_University&gt; @{ Page....
3
4,399
ChartJS, nested flexbox, not shrinking
<p>I have a ChartJS canvas object that is shrinking when it is in a single flexbox, but not shrinking when it is in a nested flexbox and looking for some advice on how to handle this; e.g. by simple CSS, by handling an onresize event and modifying the canvas element. I think it first start by understanding the root cau...
3
1,316
Test Exception using JUnit
<p>Test function doesn't catch expected exception as demanded value. It throws exception like an error one.</p> <p>I tried making </p> <pre><code>@Rule ExpectedException thrown = ExpectedException.none(); @Test(expected = UnsupportedOperationException.class) public void testNotAddingDifferentCurrency(){ ...
3
1,230
Getting "Cannot charge a customer that has no active card" on php stripe
<p>I'm trying to create a customer before i charge them. on my <code>charge.php</code> file i have this.</p> <pre><code>if (isset($_POST['stripeToken'])) { \Stripe\Stripe::setApiKey('___stripe_secret_key_____'); $api_error = false; $token = $_POST['stripeToken']; try { ...
3
1,971
v-for set current border color after click
<p>I have a vue components who loads a list of users:</p> <pre><code> &lt;div v-for=&quot;(user, index) in users&quot; class=&quot;user rounded-md border px-5 py-3 mr-5&quot; :class=&quot;{ 'border-gray-400':!isp &amp;&amp; !isa &amp;&amp; !isi, 'border-green-400': isp, 'border-red-400': ...
3
1,966
Poetry: Max retries exceeded with url in gitlab runner
<p>I have a simple <code>.gitlab-ci.yml</code> script that builds my python project.</p> <pre class="lang-yml prettyprint-override"><code>image: python:3.9.6-slim-buster variables: PIP_DEFAULT_TIMEOUT: 300 before_script: - pip install poetry==1.1.7 - poetry config virtualenvs.create false - poetry insta...
3
1,154
Unable to click a button inside iframe which itself is inside shadow root in Selenium WebDriver using Java
<pre><code>driver.get(&quot;https://thesportstak.com/&quot;); Thread.sleep(4000); WebElement scrollStory = driver.findElement(By.xpath(&quot;//div[@id='story3']&quot;)); WebDriverWait wait = new WebDriverWait(driver, Duration.ofSeconds(3)); wait.until(ExpectedConditions.visibilityOf(scrollSto...
3
1,047
Android How to sort data that i retrieve from Database
<p>I already have a code that get the Data from Firestore Database, the data consist of Date,Invoice numb, item type, qty and price. What i want is when i show it to recyclerview, the data is sorted asscendingly based on the invoice number. anybody know how ? thanks</p> <pre><code>private void filterSearch() { ...
3
1,116
How can I transform a multi-index pivot table to a nested list including part of the index?
<p><strong>Update:</strong> I really tried to have my example representative, turns out it wasn't. I updated the question as the spirit is the same, just a little more complicated.</p> <hr /> <p>I'm working with a big Pandas dataset that I want to extract data from for plotting. This small example should illustrate it:...
3
1,155
Incompatible shapes: [128,28] vs. [128,29] in validation
<p>I am training a seq2seq model.i have a training set with (x,1212) shape and validation set with (x,29) shape. when i try to train my below model. it is throwing me an error in validation.</p> <p>Error:</p> <blockquote> <p>File "C:\Users\X\eclipse-workspace\TextSummerization\main\process.py", line 184, in ...
3
1,653
Constructing a insert query based on a LINQ query
<p>I am trying to build a sql insert query based on the number of filled out textboxes returned from a <code>LINQ</code> query. Basically, the start of the textboxes start at the tab index number 13 and ends at the tab index number 33 and adds the non empty textboxes to a <code>keyvaluepair</code> list. The issue that ...
3
1,200
Getting access to input value that are dynamicallu created in a shiny module
<p>I've created a Shiny app that works just fine but my next step is to create a module that allows other people who work with me to create apps that do the same without having to rewrite completely the code.</p> <p>The main change would be on the numbers of numeric parameters that are asked as an input. My goal was to...
3
1,210
Creating Python Package (setuptools) - No module named
<p>I'm trying to create a python package for the first time, using <code>setuptools</code>.</p> <p>Let's imagine my package is named <code>qwerty</code>.<br /> Here's my project structure:</p> <pre><code>qwerty (folder) ++ src (folder) --++ __init__.py --++ control.py --++ modes.py --++ data.dic --++ utils.py --++ vers...
3
1,450
Error generating a .record file in TensorFlow
<p>I was having one similar error and to fix it I used AttributeError: module 'tensorflow' has no attribute 'app' as a solution from <a href="https://stackoverflow.com/questions/58258003/attributeerror-module-tensorflow-has-no-attribute-app">AttributeError: module &#39;tensorflow&#39; has no attribute &#39;app&#39;</a>...
3
1,229
Handle (skip) UnauthorizedAccessException in EnumerateFiles() LINQ C#
<p>I am trying to write a high performance file system searcher that can search unindexed drives (both local and network) very fast filtering on extensions and keywords. I am trying to achieve this using C#'s <code>DirectoryInfo.EnumerateDirectories()</code>, <code>DirectoryInfo.EnumerateFiles()</code> and LINQ queries...
3
1,350
JavaFX listView on-drag list items of type int[] ( Java Messsge:-1 )
<p>So i have quite a hard task of making my listview items dragable so i can change theyr index , items in listview are <strong>int[]</strong> so i use <code>CustomWeaponRecoilRowListCell&lt;T&gt; extends ListCell&lt;T&gt;</code> with <strong></strong> param since i dont want to encapsulate my int[] in some object and...
3
2,318
How to set a $cityError variable properly?
<p>I'm wondering what can I do to set a <code>$cityError</code> variable? I think the problem is because my <code>$cityError</code> is under the actual <code>$cityError</code> variable but I have to keep the <code>if</code> statement under my form <code>echo</code>:</p> <pre><code>echo $cityError . '&lt;form action=...
3
1,248
Unable to select the correct first row in UITableView
<p>I have a table row with 6 rows. I want to have the background colour of the first row to be different but the background color of 4th row ( index 3 ) also changes. I am adding the screenshot of the same and here is the code</p> <pre><code>import UIKit var items = ["admksalmdlsamdlsamdlkasmdlasmdlsamdlksamdlkasmdlka...
3
1,368
How can I store and lookup a Delegate Method in a dictionary based on Type?
<p>I have a an application with Multiple <strong>DataGridViews</strong>. I want to run a similar event on all of them, to check if the Data has changed when a user is Done editing a cell or has selected a different cell. To do that I've added a method to the <strong>CellEndEdit</strong> and <strong>CellValidating</st...
3
1,882
Why I obtain this HibernateException related to a named query in this Spring project?
<p>I am absolutly new in Hibernate and Spring development and I have the following problem</p> <p>I have this entity class named KM_ProjectInfoStatus that map a DB table named KM_PROJECT_INFO_STATUS, so I have this class:</p> <pre><code>package egp.prc.km.model; import javax.persistence.*; import java.io.Serializabl...
3
3,612
Com Smoketurner dropwizard-swagger with dropwizard 1.1.4 throws Null Pointer Exception at specFilter class
<p>I am trying to upgrade DropWizard version from <code>0.9.2</code> to <code>1.1.4</code>, and in turn change the <code>com.smoketurner dropwizard-swagger 1.1.1-1</code> which downloads dependencies:</p> <pre><code>io\swagger\swagger-jersey2-jaxrs\1.5.15\swagger-jersey2-jaxrs-1.5.15.jar io\swagger\swagger-jaxrs\1.5....
3
1,435
Checksum at the Type Level using Shapeless
<p>I came up with the following per this <a href="http://codingdojo.org/kata/BankOCR/" rel="nofollow noreferrer">problem</a>:</p> <p><a href="https://i.stack.imgur.com/L5ukB.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/L5ukB.png" alt="enter image description here"></a></p> <pre><code>package net...
3
1,331
An equals() method that determines two Participants is not working
<p>What am I doing wrong?</p> <p>Question is how I will include an <code>equals()</code> method that determines two <code>Participant</code>s are equal if they have the same values in all three fields? Include a constructor that assigns parameter values to each field and a <code>toString()</code> method that returns a...
3
1,660
Inserting and Joining tables at the same time
<p>I am trying to insert some values to the database via a form, but for that to happen tables must be joined, and the way that I have done it is not not working for me.... As it relates to the security issues in the code, that will be dealt with after, but for now I would be extremely grateful for some help...the data...
3
2,442
Karma test in Angular isn't doing what it is expected to
<p>My login controller is:</p> <pre><code>angular.module('mean').controller('LoginController', ['$scope', '$location', '$rootScope', 'UserService', function ($scope, $location, $rootScope, UserService) { $scope.init = function() { $scope.credentials = {}; $scope.status_object = { text: '', class:...
3
1,058
Android MotionLayout starts to transition to start when NestedScrollView is not on top
<p>The problem is that my MotionLayout starts to transition to start position when NestedScrollView is not on top. It goes to end correctly - when I start swiping my nestedScrollView to bottom. Going to start position of animation should be only if NestedScrollView reaches top but now animation to start position goes a...
3
2,762
Vista 64 bit BSOD when running a Delphi 2009 Application
<p>I have an application that I have converted to Delphi 2009 I have "String format checking" On and the standard memory manager. I downloaded the MS debugging tools at <a href="http://www.microsoft.com/whdc/devtools/debugging/install64bit.mspx" rel="nofollow noreferrer">http://www.microsoft.com/whdc/devtools/debugging...
3
2,957
LLVM IR -- how to convert array store to memcpy?
<p>LLVM IR includes arrays as a base type, so a "store" instruction in IR will take an array object and store it to a pointer to memory.</p> <p>I'm compiling to a C environment, so I need to convert "store" instructions to calls to memcpy. I've tried to use IRBuilder to make the job easier, but I'm stuck on how to ta...
3
1,220
Why some tabs of my deployed shiny dashboard are displaying errors yet they are working smoothly on local computer?
<p>I have built the interactive shiny dashboard to regular monitor the live tweets and underlying sentiments for different Twitter users. Fortunately, it is locally working as it is expected, but after being deployed on shinyapps.io, some of the tabs are not displaying the graphs (i.e probably the tweets are not automa...
3
2,434
how to add multiple elements in row bootstrap 4
<p>I am new to bootsrtap-4 I am designing one page in HTML using bootstrap-4, But facing some issue while to make it responsive it should work in e.g, Laptop-L,Laptop-M and i-padd, while design it, its working in only for Laptop-L not M size and i-padd, can someone see me code and tell me what should i do to design thi...
3
1,727
Unable to connect to docker.sock when it exist with permissions running inside docker container
<p>I'm setting up a base image that has docker installed and configured so when I run my jenkins pipeline I can do anchore scanning. I have to pull the anchore image inside the docker image because my pipeline is running on a docker agent. However, even running locally trying to build a docker image and just run a simp...
3
3,089
Any efficient way to obtain area estimation with pixel counting approach for land cover raster in R?
<p>I want to get area estimation for each polygon by using pixel counting method. The original landcover map was raster data that come with a distinctive class assigned to each pixel (<a href="http://jmp.sh/F6x5pcJhttp://jmp.sh/F6x5pcJ" rel="nofollow noreferrer">landcover map legend</a>). However, to get area estimatio...
3
1,210
datetimepicker is not displaying calendar using NgRoute of AngularJs
<p>I'm having some problems when I tried to open a calendar using jquery ui thru NgRoute Angularjs. I've tried removing ng-view tag and it works fine. i need it working with NgRoute.</p> <p>index.html</p> <pre><code>&lt;!DOCTYPE html&gt; &lt;html ng-app="mainApp"&gt; &lt;head lang="en"&gt; &lt;title&gt;AngularJS R...
3
1,353
Polymorphic behavior with link_to
<p>I'm facing kind of a tricky challenge here, maybe one of you could help me on this. Nothing too hard, I just don't know the good way to go. Here comes:</p> <p>I have 2 models:</p> <p><code>Activity</code> and <code>Comment</code></p> <p>I'm using MongoID here with a famous gem to handle votes (likes). It only tak...
3
1,172
Why My Javascript random selector not working?
<p>I want some help on this problem. I'm trying to get my JavaScript to highlight random picks that I enter in but its not working.</p> <p>I keep getting a error message when I inspect my JS code on the webpage saying</p> <pre><code>&quot;Uncaught TypeError: Cannot read properties of undefined (reading 'classList') ...
3
1,217
New to Web development not sure how to fix reactjs errors
<p>These is a long page full for error messages and I cannot get hold of the person teaching this class been 2 weeks. I tried redoing it but I still got the same messages I do not know how or what to do in order to fix them. Here is the git hub link: <a href="https://github.com/SadiaSanam/petshop" rel="nofollow norefe...
3
3,847
ERROR TypeError: Class constructor EventEmitter cannot be invoked without 'new' in Ionic 4
<p>In ionic 4, <code>ionic serve</code> completed successfully. When I open the application in the browser, I'm getting the below error and nothing is loading.</p> <pre><code>AppComponent_Host.ngfactory.js? [sm]:1 ERROR TypeError: Class constructor EventEmitter cannot be invoked without 'new' at new BackButtonEmit...
3
2,021
Convert XML response date format from YYYY-MM-DDT00:00:00 into DD/MM/YYYY using XSLT
<p>My <strong>XML</strong> response version "1.0" is presenting different collection dates in an array in element and the format is 2019-04-04T00:00:00 and I want to use <strong>XSLT</strong> version "1.0" to convert the date format to 04/04/2019 (DD/MM/YYYY) in each recurring element. I have tried looking for a few ...
3
3,165