Skip to main content
The 2024 Developer Survey results are live! See the results

Questions tagged [optimization]

Optimization is the act of improving a method or design. In programming, optimization usually takes the form of increasing the speed of an algorithm, or reducing the resources it requires. Another meaning of optimization is numerical optimization algorithms used in machine learning.

0 votes
0 answers
32 views

Easy way to autonomous periodic data update in Laravel, PHP

How can I autonomous calculate and update value for one column in my Laravel project? I have no much experience in web-dev, so I just dont how to do it effective. For example, now I've column "...
dekma_d's user avatar
0 votes
0 answers
21 views

Python script gets stuck due to mysql query running for longer period

Mysql version - 5.7 Python version - 3.9.2 I have a dynamic mysql query, which sometimes runs for over 10 mins or something and the mysql's set timeout has been set to around 1 minute. Which is why i ...
Sahil Daryani's user avatar
0 votes
0 answers
16 views

Linked Stylesheets in Angular: Understanding Inline Inconsistencies

I ran into a problem with how Angular handles styles: With some linked stylesheets, Angular makes them inline on build, but with other linked stylesheets it doesn't. In neither case are any of these ...
Valentin Haakonsson's user avatar
-1 votes
0 answers
11 views

How can you appropriately combine multiple loss conditions for an optimization problem

I have a noisy signal (tri-exponential decay) that I am trying to extract parameters from using a global optimization function. The main issue with this is that the loss landscape of the signal has a ...
Oliver Nicholls's user avatar
0 votes
2 answers
66 views

Write an algorithm in Python to find the smallest circle that can enclose a polygon

Write an algorithm in Python to find the smallest circle that can enclose a polygon. The polygon is defined as a set of coordinates that map the vertices inside a 2D plane. This is known as the ...
makeyourownmaker's user avatar
-3 votes
0 answers
22 views

Is there a way to reduce the number of triangles/polygons for a 3D model (.glb/.obj/.fbx) using code such that quality is not hampered a lot?

Is there a way to reduce the number of triangles/polygons for a 3D model (.glb/.obj/.fbx) using python code. I have tried using pymeshlabs and open3D module, but for some reason none of the things ...
kaustubh's user avatar
0 votes
0 answers
14 views

PyTorch zeroGrad() Equivalent in DiffSharp?

What is the PyTorch zeroGrad() Equivalent in DiffSharp? Doesn't seem to exist any quivalent member function of the Optimizer class.
Loco Barocco's user avatar
0 votes
1 answer
22 views

mlrMBO Error in validObject(model, complete = TRUE)

I'm trying to recreate the example from here using my data, but I'm getting an error x <- structure(list(`1` = c(0L, 0L, 0L, 0L, 0L), `2` = c(0L, 0L, 0L, 0L, 0L), ...
mr.T's user avatar
  • 598
0 votes
0 answers
21 views

Minimize submatrix rank under constraints

I have a n by 2n binary matrix. I want to find a combination of m unique columns (for a fixed m), so that the new n by m matrix’s rank is minimized. My only constraint is that if I include column k, I ...
big_qubit's user avatar
0 votes
0 answers
27 views

Least squared optimization with SciPy but without smoothing

I'm currently trying to unfold the neutron spectrum using Bonner spheres spectrometry (which is essentially an under-determined problem). I have been using least_squares from scipy.optimize but I'm ...
Hitman01's user avatar
3 votes
2 answers
102 views

Optimizing code for detecting adjacent items in an array with SIMD instructions?

I have a function written in C++ that checks if two specific elements are adjacent to each other in an array. The function works fine, but I want to optimize it using SIMD to improve performance. Here ...
UndefinedCpp's user avatar
-2 votes
0 answers
14 views

Optimize Redux Data Updates

I am building a chat app with React/Redux. I want to store the messages state using Redux, it currently works with this code: // chatsReducer.js import { GET_CHATS_PENDING, GET_CHATS_SUCCESS, ...
Adrian John's user avatar
1 vote
0 answers
31 views

Find the portfolio with the maximum return at a given risk level using the `fPortfolio` package in `R`

I’m trying to find the portfolio with the maximum return at a given risk level using the fPortfolio package in R. However, there appears to be a bug in the package that the optimal portfolio (based on ...
itpetersen's user avatar
  • 1,495
0 votes
1 answer
31 views

simplification of minimizing f(x) with constraint f(x)<a

For the optimization problem: min f(x) s.t. f(x)<a Can I simplify this problem by ignoring the constraint and then check the feasibility of the solution, which mean minimize f(x) without ...
Wang Sarah's user avatar
3 votes
2 answers
105 views

A more efficient algorithm in finding the number of distinct decompositions a number has using only repdigits

This is a problem from a previous semester that I am trying to upsolve. I am trying to solve a problem involving the total number of ways of decomposing a number using only repdigits. A repdigit is a ...
Lesserrafim's user avatar

15 30 50 per page
1
2 3 4 5
2654