Quantcast
Channel: User Connor - Stack Overflow
Browsing latest articles
Browse All 44 View Live

Comment by Connor on Can I get %rsp with inline assembly?

@fuz I'm afraid that doesn't work either! It's a coding challenge and the builtins have been switched off!

View Article



Comment by Connor on Why are %rbp and %rax invalid operands for movl?

Oh weird! When I looked it up it said movl was for 64bit. Am I completely wrong, or does it differ?

View Article

Comment by Connor on Why are %rbp and %rax invalid operands for movl?

I had a different error before that using movl fixed, so I assumed that wasn't the issue! Thank you, changing to mov let it compile. You're right, this is an XY, problem, I've posted a question about...

View Article

Comment by Connor on Why are my char arrays returning a null value?

Okay, so I'm allocating memory and then giving the address to a local pointer. But that address isn't preserved outside of the function, so the memory remains allocated without a reference?

View Article

Comment by Connor on How do Jupyter Notebook extensions add functionality to...

Thank you for the reference! Do you think there's a way of replicating the behaviour using JSON?

View Article


Comment by Connor on SHAP not working with LightGBM categorical features

Are the SHAP values meaningful when calculated this way?

View Article

Answer by Connor for What does `amd64` mean in Python .whl files?

Basic TakeawayYou can download the amd64 version of the file.AMD64 is the standard name given to the 64-bit x86 architecture, which your Intel chip probably uses. You can read more about x86-64...

View Article

What does `amd64` mean in Python .whl files?

I'm trying to download some Python .whl files, but I'm not sure what version I should be downloading.I have a windows machine with an Intel chip, but all the versions I see use amd64, does that mean...

View Article


Can Google App Scripts create Web Apps with Multiple User Accounts?

I would like to create a web app that provides a dashboard visualisation of data from a Google spreadsheet.From reading around it seems it's quite easy to do this, however, I would like the web app to...

View Article


Why doesn't passing an address to a pointer array store that unique value?

I'm trying to create a pointer array that holds strings of various sizes. I want to prompt the user for input, store the values in the array, and then print them using the following code:#include...

View Article

Why use a superclass's __init__ to change it into a subclass?

I'm working on replicating the SHAP package algorithm - an explainability algorithm for machine learning. I've been reading through the author's code, and I've come across a pattern I've never seen...

View Article

Can you dynamically initialize stack memory to zero?

I have an integer array that's only useful in a single code block. I'd like to declare it and initialise it to zero on the stack to avoid the overhead of the heap.I'd like to do this dynamically and...

View Article

Why does memset fail and calloc succeed?

I'm trying to initialise an array of 26 strings. I'd prefer not to place the array on the heap, but I get a segmentation fault when I try to assign memory to the array using memset. The code to...

View Article


Is array declaration notation a shorthand for malloc in C?

From this tutorial website:To declare an array in C, a programmer specifies the type of theelements and the number of elements required by an array as follows −type arrayName [ arraySize ];It seems...

View Article

Which Design Pattern combines an Interface, a Factory, and Data?

ProblemI've tried reading this resource on the naming conventions for common Python design patterns, but I can't find a pattern that matches the class I'm creating.The closest I could find was the...

View Article


Is there a standard C library for dynamic arrays?

One of the greatest things about Python is the flexibility of dynamic arrays (lists).It's so useful I find it hard to believe there isn't a library for this already included in C. This question...

View Article

What's the fastest way to append to a list with Numba?

I'm creating some code that does a lot of list appends. It has to be performant so I'm using Numba to @jit compile it.I've checked the Numba documentation on lists, but it doesn't give much information...

View Article


Is it possible to create a character array within a strcpy?

Is it possible to copy a string using C's strcpy without first assigning memory to a char *character_array?Basically, is something like this possible:strcpy(char *my_string, another_string);where...

View Article

Can you qsort part of an array?

I'd like to qsort the first 100 elements in an integer array and leave the remaining elements untouched.I'm currently trying to do this with the following call:int cmpfunc(const void *a, const void...

View Article

Why is pandas.read_sas() making random mistakes?

I'm trying to work on a SAS dataset using pandas. The dataset is in sas7bdat format, and is encoded in iso-8859-15. The dataset is 230,000 rows long and 1300 columns wide.I'm using the following...

View Article

Is there a shorthand for the unsigned long long type?

The type:unsigned long long my_num;seems cumbersome. I seem to recall seeing a shorthand for it, something like:ull my_num;Am I going mad, or is there a simpler way of writing unsigned long long?

View Article


Why are my char arrays returning a null value? [duplicate]

I'm trying to write a function that reads values into a pointer array to store strings of variable lengths. The strings appear to be stored correctly in get_input, but have a null value when printed in...

View Article


How do you set up an array in Experian's PowerCurve Script?

Experian's PowerCurve software has an internal scripting language. The documentation on this software is limited and I can't figure out how or even if it's possible to implement an array.How do you set...

View Article

How can I create a Timer app using Jetpack Compose? [closed]

As the the compose UI tools seem a lot simpler I imagine there is a relatively easy way to do this, but I haven't been able to find a sample project online, or in any tutorials.The idea is simple, a...

View Article

How do Jupyter Notebook extensions add functionality to a notebook?

Given that behind the scenes the data in a Jupyter notebook is JSON, I assume that a similar simple system is used for notebook extensions.However, I haven't been able to figure out exactly how they...

View Article


What's best practice for reading RSS feeds from a single machine?

BackgroundI'm trying to create my own RSS feed reader, mainly drawing stories from Medium.At the moment I'm testing and working off my own machine, and I can't access multiple IP addresses.I have about...

View Article

Can MLFlow be used without the `with mlflow.start_run()` block?

I want to track an entire notebook and log the parameters of cleaning steps that occur before training a model. I'd like to use mlflow to do it, but on all the docs it looks like you have to track...

View Article

Answer by Connor for Can MLFlow be used without the `with mlflow.start_run()`...

Yes, it's possible to start and end an mlflow run without the context manager syntax.To do this you can simply write:mflow.start_run()...your_run_code_here...mlflow.end_run()You can read more about it...

View Article

Comment by Connor on How can you colour a matplotlib plot to show point density?

That looks good! Is there a way to do it with alpha values as well?

View Article



Image may be NSFW.
Clik here to view.

How can you colour a matplotlib plot to show point density?

I'm plotting some partial dependency plots using matplotlib. I have 1,000 samples which I produce regression predictions for. These predictions are plotted on the y-axis. To get an overview of partial...

View Article

Comment by Connor on Why do multiple conditions in the $match operator fail...

Okay, so is that the issue do you think? It would be executable if they were different fields?

View Article

Does the folder created by `npm run build` contain the react runtime engine?

I've read that React can be thought of as a UI Runtime, which made me think it was an application that ran on a server.Further research showed this was false, and React apps can be served statically....

View Article

Are their built-in Toggle Switches in HTML5?

I've been looking for a good way to put a toggle switch into a design. But, when searching for a standard way to do this, all I came across are toggle switches created through a combination of HTML and...

View Article


How do you run an Appscript on Form Submission?

I'm trying to create Google Form that redirects to a Web App when a user finishes a form submission.I have checked the Google Developer documentation, but I can't see an easy way to do this. I have...

View Article

Can Anaconda tell you Conda-Forge url of an installed package?

I'm trying to build a dependency tree for a series of python package installs, and I'd like to include the conda-forge url for each package.Is there a way to find the url of an installed package using...

View Article
Browsing latest articles
Browse All 44 View Live




Latest Images