As of May 31, 2023, we have updated our Code of Conduct.

Questions tagged [performance]

For questions pertaining to the measurement or improvement of code and application efficiency.

Filter by
Sorted by
Tagged with
0 votes
0 answers
13 views

Any ideas on why my chess engine evaluation function is slowing down the search so much?

I'm creating a chess engine and doing it in Rust, both of which I am relatively new to, and am working on the search and evaluation functionality to find the best move. I have implemented a negamax ...
Gwoodz's user avatar
  • 23
0 votes
0 answers
31 views

Loss of data in simultaneous threads (JAVA)

I have a problem Currently I have a function in JAVA that writes 8 simultaneous threads, it has to be that way because each writeCmd function takes around 2 minutes, (if I write 1 by 1 it would take ...
R.Lerma's user avatar
1 vote
1 answer
22 views

Is there a better way to publish messages using Pusher Channels' batch event?

I'm trying to send messages to my users from my server using Pusher Channels. My api receives a list of users and the message needs to be sent to all the users in the list. I can't group these users ...
Milind Mohapatra's user avatar
6 votes
3 answers
81 views

Efficiently match all values of x in y

I'm looking to find an efficient method of matching all values of vector x in vector y rather than just the first position, as is returned by match(). What I'm after essentially is the default ...
Ritchie Sacramento's user avatar
0 votes
1 answer
13 views

How can I use Webpack to load a separate JS file in Shopware 6 and improve web performance?

How to load a separate JS file in Shopware 6 using webpack? What? I'm trying to load a separate javascript file next to the all.js file by using WebPack. Why? The all.js file can get really big and ...
Jesper Ingels's user avatar
-3 votes
0 answers
18 views

Need help for Web AR application [closed]

We are developing a restaurant menu with Web AR. And for that, we are using the Mindar.js library. But we have 2 problems 1- The 3D object of the dishes are too big (~30MiB) and we have 20 objects in ...
Volker Deppe's user avatar
-6 votes
0 answers
24 views

Machine Learning for Linear Equation Prediction [closed]

You are tasked with developing a machine learning model that can predict linear equations based on a given dataset. The dataset consists of pairs of input variables and corresponding output values, ...
Monikbudhv113's user avatar
0 votes
0 answers
21 views

code should explicitly check to see if permission is available (with checkPermission) or explicitly handle a potential SecurityException

I am trying to make Bluetooth chatting app. I have two activities in it: please please see it is a short project git repo:https://github.com/soam1/BlueToothChattingApp.git 1.MainActivity 2....
Akash Soam's user avatar
0 votes
0 answers
11 views

How do I speed up an R module in python?

I'm using optuna for hyperparameter-tuning and the detrended cross-correlation coefficient (rhodccc) as metric that should be optimized. Its an R module that I imported to Python using rpy2. As I've ...
Good Question's user avatar
0 votes
0 answers
68 views

Performace issue with NestJs Application with Scale. Global gurads taking too long to process

I am running a NestJs application hosted on AWS EC2 (with Elastic Beanstalk). It was running just fine until a couple of days ago, now my application is intermittently crashing with numerous ...
Ankur's user avatar
  • 1
-1 votes
0 answers
7 views

Can I have some ideas on how to start coding an ordering and online payment pay python

I have to code an ordering and online payment system but I do not know how to start and where should I start researching from I tried looking up for some examples of online payment system. I’m ...
Wendy 's user avatar
-1 votes
0 answers
11 views

WordPress Page speed,

i have desktop speed 100.but mobile speed up is 90.low range for the fcp and lcp.fcp was 2.1s and lcp was 3.0s .am already install wp - rocket .but fcb and lcp was very low .how to improve My FCP and ...
Saravana kumar's user avatar
0 votes
0 answers
10 views

Increasing performance losses when creating many tf.data.Datasets and sampling from them

To implement an ERP (Experience Replay Buffer) in TensorFlow I'm trying the following: I have some function, which creates and caches a tf.data.Dataset: def create_data(): my_data_ndarray = ...
LJKS's user avatar
  • 889
1 vote
0 answers
36 views

Have you found the pcmpestri / pcmpistri x86 instructions too slow to be worthwhile when compared to alternatives? [closed]

My main question: on x86, have you found it quicker to use your own algorithms compared to pcmpestri instructions? (Or even pcmpistri which is/was supposed to be significantly faster ? ) I haven’t yet ...
Cecil Ward's user avatar
-3 votes
1 answer
33 views

Fast way to find substrings of a query

I have a practical problem to do with finding any strings that form the beginning of a given query string and I can't find a suitable method for doing it quickly at scale. (specifically not trying to ...
FuchsiaSoft's user avatar
-1 votes
0 answers
10 views

Determining the big-O runtimes of loop

if ( A > B ) { for ( i=0; i<N; i++ ) for ( j=N*N; j>i; j-- ) A += B; } else { for ( i=0; i<N*2; i++ ) for ( j=N*2; j>i; j-- ) A += B; } ...
me luobote's user avatar
0 votes
0 answers
22 views

How much do conditional operators affect performance in js?

I am developing a js whiteboard app. For drawing purposes I use mousedown, mousemove and mouseup events. In mousemove handler I have code like this: function handleMouseMove(tool){ if (tool === 'pen'...
veb1's user avatar
  • 1
0 votes
1 answer
16 views

What is the most efficient way to remove tracking, marketing, etc query parameters from a URL in .NET? [closed]

So, I have an issue. I need to try and get as "clean" or a URL as possible; meaning removing unnecessary query parameters from an URL. I realize that this would be close to impossible to do, ...
AJ Tatum's user avatar
  • 643
-1 votes
0 answers
30 views

Computation of average speed in python [closed]

someone can help me with this code? I'm trying to compute the average speed every 100 m, starting from a list of spans that contains [distance, time, avg speed]. This is what I've tried to do, and ...
Fabio's user avatar
  • 1
1 vote
2 answers
57 views

How can I improve the for loop performance?

When belgeList.length = 200, it completes the loop in 16 seconds. However, when I want to list more than 200, I expect more. How can i speed up this for loop? internal DtResult documentCheckList(...
Büşra Güler's user avatar
0 votes
0 answers
20 views

RStudio unresponsive console and GUI

Over the past year I have started having occasional performance issues with RStudio that make it run increasingly slow/sluggish: whenever called, the RStudio console (and eventually, the entire GUI) ...
Juan Manuel Alzate Vanegas's user avatar
0 votes
0 answers
38 views

Deep learning model training troubleshooting : Loss and accuracy are not improving

I replicated a deep learning model from a research paper, I replicated the same dataset, model (got the model from their github repository) and hyperparameters stated in the paper, they got an ...
Repo1's user avatar
  • 11
0 votes
0 answers
32 views

Why is my OpenMP code experiencing high latency in production despite performing well in development environment?

Below is a parallel task model using omp. The proc1, ..., proc4 each costs below 1ms to finish. And in develop environment(2 physical CPU, 16 core in total) the job finishes perfectly. But in ...
Pandoxie's user avatar
0 votes
0 answers
16 views

ArangoDB read requests getting limited to a certain number [closed]

I'm using Arango in standalone mode(single node), with machine specs of 16gb RAM and 8 cores. No other process is running on the machine. I have some 4000 collections each having 15000 documents ...
Yash Bansal's user avatar
-1 votes
0 answers
38 views

Most efficient way to populate an existing struct from a tuple in C++? [duplicate]

This is a followup to another question I asked earlier. Say I have: struct foo { int x; std::string y; some_big_class z; }; foo s; Now I am iterating over a bunch of tuple<int, std::string, ...
flyfisher's user avatar
0 votes
0 answers
4 views

Is it possible to fit 8.2 million of triangles in a VR scene for a standalone HMD?

I'm making a VR application where a 3D map is displayed. I'm using Unity 2021.3.22 and XR Interaction Toolkit. I've been able to represent buildings by using GIS data. The problem is that the number ...
Antonio Serrano's user avatar
0 votes
0 answers
8 views

The advantage of HWUI rendering and overdraw

Is the HWUI rendering and the GPU Overdraw tool from app developer options useful with Jetpack Compose? I tried it out, and some areas were seen to be overdrawing, and it seems like it is useful, but ...
Makiwe Lewel's user avatar
0 votes
1 answer
36 views

Why is SVC().decision_function() so slow?

I'm trying to use sklearn.svm.SVC on a large dataset (without much success), and I came upon an interesting phenomena: somewhy, SVC().decision_function() is significantly slower than SVC().predict (~...
Ilya Kuleshov's user avatar
0 votes
2 answers
47 views

Is there a way to optimize a LINQ query with multiple sum operations on a large table in C# using Entity Framework?

I'm making this linq query to a bigger table in which I make several columns sum and takes so long var returnList = context.Revenue_Consolidate.Select(b => new { b.field, b.GrsVol, b.Type, b....
David Zamudio's user avatar
0 votes
2 answers
41 views

Parsing Prometheus promo format using PowerShell

I've looked around a while for how to go about to parse a Prometheus promo answer using PowerShell. # HELP CPU_Total Total CPU load in percent of all processors combined. # TYPE CPU_Total gauge ...
Dennis's user avatar
  • 778
1 vote
1 answer
44 views

Shifting values of avx2 packed single vector [duplicate]

I am trying to perform a right shift operation on a packed single vector using avx2 intrinsics in C++, and I cannot get it to work. float data[8] = {1.0f, 2.0f, 3.0f, 4.0f, 5.0f, 6.0f, 7.0f, 8.0f}; ...
DNF's user avatar
  • 11.3k
0 votes
0 answers
22 views

running code in two gpus consume more time, when run independently, as compared to running in a single one

I am trying to inference model with the best possible speed. While testing, I found that one inference take 34 milliseconds ( on average), when run on one GPU. And one inference ( on average) take 40 ...
Basir Mahmood's user avatar
0 votes
0 answers
31 views

I am reading specific numbers from a large file and writing them to more large files is there a way to decrease computing time?

I have a code that reads a large file (200 000 kB). Basically what i need to do is compare two lines at a time and write the difference between the numbers on line n and line n-1 to a new file. Now im ...
Babydemon's user avatar
-1 votes
0 answers
48 views

How can we optimize Apache (PHP, Symfony) performance to handle 2000 users in 240 seconds without CPU overload? [closed]

We perform performance tests of our application (with jmeter) for a scenario where 2000 users perform various actions on the website in 300 seconds. For these parameters max. cpu usage is 30% and the ...
MaciekS's user avatar
1 vote
1 answer
41 views

Azure SQL: How to decide a time to launch automatic calculation to avoid a performance peek?

Context: The web application needs to pre-calculate some information in advance to be more responsive and giving a feeling to see "as if on-line data". We have the mechanism that says "...
pepr's user avatar
  • 19.9k
0 votes
0 answers
18 views

Is there a neater way of traversing metric object lookups for PrometheusExporter in PowerShell?

I'm building a script for exporting Performance Monitor metrics to Prometheus using the module PS Gallery - PrometheusExporter specifying the metrics to use in a json. Since the Prometheus-format isn'...
Dennis's user avatar
  • 778
0 votes
0 answers
9 views

How to speed up 3D Ising Model simulation with Python multiprocessing?

So I am trying to simulate the 3D Ising Model to generate magnetization values for a given temperature and lattice size using the Wolff Cluster Algorithm. I'm using Python to run all my codes and have ...
Praveen Murali's user avatar
0 votes
1 answer
25 views

Try to optimize/improve my query, where I bring the number of orders and a column for each filter that I apply

I'm trying to get the number of orders for different businesses So, I have two tables: Table1: Order_Number Order_Date Store_ID Customer_ID Is_Valid 1 01-01-2020 55 25 Valid 2 24-05-2020 90 34 ...
Alan Iza's user avatar
3 votes
1 answer
47 views

Overhead when using vector-valued functions in Julia

I have noticed that, in Julia, the execution speed of my code slows down dramatically when using vector-valued functions. Consider the following MWE: using BenchmarkTools function f_scalar(x::Float64)...
Andreas's user avatar
  • 73
-1 votes
1 answer
29 views

How does google process 600K documents in .33 seconds? [closed]

Regardless of fast their CPUs are,it seems impossible to process that many documents in .33 seconds. So I believe that it comes down to horizontal scaling. As a guess, how many servers were involved ...
Bear Bile Farming is Torture's user avatar
0 votes
1 answer
108 views

method to make this for-loop faster in C++ possibly with NVidia?

I want to make a C++ function faster. I am asking you about potential ways to do it. I can use up to 32 OMP threads. I can use an NVidia GPU. A MWE for the function is: #include <iostream> #...
velenos14's user avatar
  • 474
0 votes
0 answers
16 views

Cloudfront.net Main Thread Blocking Time?

My web app uses cloudfront.net as a CDN. Google Lighthouse is saying it adds 598ms to my main-thread blocking time: Does Lighthouse mean that cloudfront.net could be accessed in a non-render-blocking ...
VikR's user avatar
  • 4,710
0 votes
1 answer
38 views

Partitioning time series data that is user specific [closed]

We are building a website that will hold time series data for each user. We expect a large amount of time series data so we are thinking about partitioning the table that holds the data so that the ...
helloworld's user avatar
1 vote
0 answers
52 views

C# Lock contention on structs?

I'm playing with structs in C# which look like this: public struct UnitData { public int ID { get; init; } public Vector2 XY { get; set; } } and while profiling I seem to get a significant ...
user3797758's user avatar
7 votes
3 answers
450 views

Numbers of combinations modulo m, efficiently

First of all I'm solving a programming problem rather than a math problem now. The question is Anish got an unbiased coin and he tossed it n times and he asked Gourabh to count all the number of ...
Adithya's user avatar
  • 189
2 votes
3 answers
62 views

Faster algorithm to calculate similarity between points in space

I am trying to calculate some kind of similarity between points with coordinates in geographical space. I will use an example to make things a bit more clear: import pandas as pd import geopandas as ...
Mirko's user avatar
  • 95
-5 votes
0 answers
21 views

What is the best way to reduce React app renders to one when using useCallback and useEffect? [closed]

I am currently working on optimizing my React app. In the network console, I noticed that it renders three times, but I want it to render only once. To achieve this, I initially attempted to use ...
Gr8fulnez's user avatar
-1 votes
0 answers
53 views

How do I check which method is faster? [duplicate]

I am trying to design the most performance friendly way to set any string to title-case (every word's first letter is capitalized) I have come up with two different methods, since strings are ...
Ieris19's user avatar
  • 41
0 votes
0 answers
20 views

How can I speed up a Spark job that transforms a large denormalized dataset into a parquet file with multiple struct schemas?

I'm trying to use Spark to transform a denormalized dataset into a structure that groups data into columns, where each column has its own struct schema. I have an input parquet file with data that ...
jxc454's user avatar
  • 1
-1 votes
0 answers
35 views

Producer Consumer with PriorityQueue

I need to implement the Producer Consumer pattern with priorities and I'm searching the best option in terms of robust and performance. These are my requirements Multiple Threads can enqueue elements ...
JuanDYB's user avatar
  • 568

1
2 3 4 5
2013