All Questions
5,949 questions
0
votes
1
answer
69
views
Error "metadata-generation-failed" when installing langchain-core dependencies on Windows (NumPy build failure using Meson)
I'm trying to install the following packages for my FastAPI project that uses LangChain with Pinecone and Google GenAI:
langchain-core langchain-pinecone langchain-google-genai pinecone-client
I run ...
0
votes
2
answers
80
views
How to create a numpy.array from a list of floats with shared-memory with version 2.1.3
I am trying to create a numpy array from a list of floats with shared-memory such that updating the list updates the numpy array.
import numpy as np
lists = [[1]]
arr = np.asarray(lists, dtype=object) ...
0
votes
0
answers
92
views
Why does torch import complain about numpy version
I created a virtual environment on MacOS and installed pytorch with pip:
python -m env torch-env
source torch-env/bin/activate
pip install torch torchvision torchaudio
Launching python and importing ...
0
votes
0
answers
106
views
What is wrong with my Python and Tensorflow install?
I work on a PC with Windows 11 and have installed Python 3.11.9 which is supposed to be the required Python version for Tensorflow. I also installed numpy 1.26.4, scipy 1.15.2, Orange3 3.38.1 which ...
0
votes
2
answers
81
views
Processing satellite conjunctions with numpy efficiently
Original Post: How to populate a 2-d numpy array with values from a third dimension?
New Post:
I'm trying to analyze interference between satellites using numpy and sgp4 python libraries, and want to ...
3
votes
2
answers
128
views
Why is this python code not running faster with parallelization?
This is a MWE of some code I'm writing to do some monte carlo exercises. I need to estimate models across draws and I'm parallelizing across models. In the MWE a "model" is just parametrized ...
4
votes
1
answer
70
views
Numpy Structured Array - Memory copy error
I am using python structured arrays to arrange relevant data then passing it into C++ land. I noticed on occasion a memory copy error which leads to calculation issues. I first explored using hashing ...
1
vote
0
answers
47
views
Python Numpy Crash without error or warning with exit code -1073740791 due to _multiarray_umath.cp312-win_amd64.pyd
Numpy library crash without console error or warning constantly
In Python Console see notifications either Process finished with exit code -1073741819 (0xC0000005) or Process finished with exit code -...
-2
votes
2
answers
141
views
Numpy installation failed on Mac M3
I am trying to install the dependencies for my Python project using the following command:
pip3 install -r requirements.txt
Requirement.txt
pyquaternion
importlib-metadata==4.13.0
Flask==2.1.1
celery=...
4
votes
4
answers
88
views
How to extinguish cycle in my code when calculating EMWA?
I'm calculating EWMA values for array of streamflow, and code is like below:
import polars as pl
import numpy as np
streamflow_data = np.arange(0, 20, 1)
adaptive_alphas = np.concatenate([np.repeat(0....
1
vote
1
answer
80
views
Integrating Chaquopy 16.0 in kotlin multiplatform's shared module, Can not access Python in shared module
I am developing a kotlin multiplatform app. In the shared module of this I want to use numpy package to do operation on some .pkl files.
I am following the setup mentioned Official Setup Link-Kotlin.
...
0
votes
1
answer
53
views
Pandas Dataframe Prints starting at Fourth Row in Excel
I am using iloc to print every third row in a Pandas Dataframe, but now when it prints to Excel, it prints starting in the fourth row (third excluding header). I want it to print starting at the first ...
0
votes
1
answer
62
views
How to convert Polars dataframe to numpy array which has certain dims?
I have a Polars DataFrame with 300 basins, each basin having 100,000 time records, and each time record consisting of 40 variables, totaling 30 million rows and 40 variables. How can I reconstruct it ...
1
vote
2
answers
333
views
I can't find a recent version of numpy
I'm in ubuntu 20.04, been trying to install a more recent version of numpy after realising I had 1.24.4 but whenever I try to update it with
pip3 install --upgrade numpy
It keeps giving me this ...
0
votes
1
answer
148
views
numpy.distutils was deprecated. How to install libtiff?
I have a series of tiff images and need to read them using the following command:
from libtiff import TIFF
tif = TIFF.open(tiff_image, mode = "r")
I cannot use Image.open as I'd like to get ...