instruction stringlengths 0 30k ⌀ |
|---|
|python|r|statistics|scipy.stats| |
null |
I'm trying to make a slider that displays 4 horizontal images at a time and each image is hyperlinked. Adding hyperlinks to it breaks the code. I added "a" tags to the CSS and expected it to continue working, but it made the slides vertical and displayed all of them, instead of just 4 at a time. Could there be a prob... |
Adding href tag to image breaks carousel? |
|java|html|css|wordpress|slider| |
null |
As mentioned by [Santiago Squarzon](https://stackoverflow.com/users/15339544/santiago-squarzon) in his helpful answer Object Graphs (resulted from cmdlets along with `ConvertFrom-Json`) could be quite difficult to handle. That's why I have been busy for the last months to create some [**Object Graph Tools**](https://gi... |
You are not using the && in the right place. If &J=1 and want the value of YY1 then you should do:
%let year_x = &&yy&j;
The first pass will convert && into & and &J into 1 resulting in &yy1. Which the second pass will convert to the value of YY1.
But you are making it much too hard. If the goal is to s... |
My Solution
try {
presenter = new NonioApplicationPresenterImpl(this);
masterHelper = presenter.getDevOpenHelper();
sqLiteDatabase = presenter.getWritableDatabase();
daoMaster = presenter.getDaoMaster();
daoSession = presenter.getNewSession();... |
I can pass a template parameter to an object's member function, but not to the object itself.
Is this possible at all?
#include <iostream>
#include <string>
using namespace std;
class Logger {
public:
Logger& operator()(int t) {
cerr << "(tag " << t << "... |
Yes, you can [add scopes to `has_many` associations](https://guides.rubyonrails.org/association_basics.html#scopes-for-has-many). But you have to add the class name to the association too, because Ruby on Rails is not able to guess it from the name anymore.
class Playlist
has_many :tracks
has_man... |
Plotting categorical covariate against occupancy using unmarked package |
|ggplot2|boxplot|categorical-data|unmarked-package| |
null |
Not a reply intended for the op but as an alternative method to anyone else looking into this topic...
You CAN use json_decode() on ANY size file with next to no memory use. Yepp, the best of both worlds. I tried several solutions such as jsonmachine and json_decode as they were designed where some methods were fast... |
TLDR: Use `@WebMvcTest`
Your test is all wrong.
There are 2 `UsersController` instances in your test.
- One is created via SpringBootTest which brings up entire application context - controllers, services etc. Some beans are overriden via `@MockBean`. This controller uses your mock service.
- The second one i... |
SSL error when redirecting from one lightsail subdomain to lightsail subdomain on different account |
|ssl|ssl-certificate| |
null |
When running expo go with my react native project- which i've been working on for some months now with no issues like this before, everything works as it should until I render a page that fetches some information from my DynamoDB database. Expo go crashes and there is no error message anywhere.
```
import { API ... |
We have built several solutions for clients based on azure functions and servicebus to move data between systems. Each solution hosts many (100+) individual functions triggering on individual topics from many different systems.
Although some solutions are older, the majority are .net 8 isolated functions and a solutio... |
Throttling consumption of Servicebus messages with azure functions |
|c#|azure-functions|azureservicebus|throttling| |
null |
I have use tinyMCEeditor CDN in my laravel application
so i want to know, where the images uploaded in tinymce are stored?
file_picker_types: 'file image media',
file_picker_callback: function (cb, value, meta) {
var input = document.createElement('input');
... |
where the images uploaded in tinymce are stored? |
Expo Go crashing with on error message using Amplify Graphql to get an item |
|graphql|expo|aws-amplify|expo-go| |
null |
I need to create multiple queries with various weightages and Properties.
The simplified version of couple of queries is this
```
SELECT Emp_Id,
(30 * ISNULL(BMI,0) +
(20 * ISNULL(Height,0) +
(10 * ISNULL(Eyesight,0)) from MyTable1 where Category = 'Fighter'
SELECT Emp_Id,
(10 * ISNULL(BMI,0) +
(... |
|android|kotlin|mobile| |
{"Voters":[{"Id":6340496,"DisplayName":"s3dev"},{"Id":298225,"DisplayName":"Eric Postpischil"},{"Id":4142924,"DisplayName":"Weather Vane"}],"SiteSpecificCloseReasonIds":[13]} |
I have a list of things and want to get them in two seperate colums. Can I do that by using search and replace ? or How do I do this ?
Here is an example
How it is

How it should be
 |
|java|apache-spark|bean-io| |
I need to create multiple queries with various weightages and Properties.
The simplified version of couple of queries is this
```
SELECT Emp_Id,
(30 * ISNULL(BMI,0) +
(20 * ISNULL(Height,0) +
(10 * ISNULL(Eyesight,0)) from MyTable1 where Category = 'Fighter'
SELECT Emp_Id,
(10 * ISNULL(BMI,0) +
(... |
{"Voters":[{"Id":1235698,"DisplayName":"Marcin Orlowski"}],"DeleteType":1} |
I have the same problem with Docker SQL Server 2019 under MacOS. I assigned 777 to the whole Data directory (from MacOS). I am able to create the new database but the restore will fail anyway even with the OVERWRITE option.
What worked for me was to restore the backup in a SQL Server running on a virtualized Window... |
I have a large CSV file without a header row, and the header is available to me as a vector. I want to use a subset of the columns of the file without loading the entire file. The subset of columns required are provided as a separate list.
```
1,2,3,4
5,6,7,8
9,10,11,12
```
```R
header <- c("A", "B", "C", "D... |
How to read specific columns of a CSV when given the header as a vector |
|r|csv|readr| |
Defining it entirely outside the class works, but feels less nice that @python_user's solution
```
class RawEmergency(InputBase, RawTables):
__tablename__ = "emergency"
id: Mapped[UNIQUEIDENTIFIER] = mapped_column(
UNIQUEIDENTIFIER(), primary_key=True, autoincrement=False
)
attendan... |
|laravel|tinymce|tinymce-6| |
I wrote a code and it works quite well. The only problem is that it takes a little too long to complete. The loop should be able to process up to a maximum of 20 data sets (10 from LOOP1 and another 10 from LOOP2) at once.
If I start the function with 2 data sets, for example, I currently have a waiting time of 10-20s... |
I have created one web application. this application I want to deploy in oracle weblogic server, but getting error "Caused By: javax.faces.FacesException: Unable to find CDI BeanManager".
How to solve this error???
Is anything need to add in this above files. I have configured datasource in weblogic server. , ens... |
weblogic.application.ModuleException: javax.faces.FacesException: Unable to find CDI BeanManager |
|java|oracle|spring-boot|maven|weblogic| |
null |
|spring|oracle-database|jpa|oracle19c| |
I've been using the React Native Video package with FlashList, and I've encountered an issue where all the videos seem to squeeze and resize themselves or flicker when they first render while scrolling. After a few seconds, they render fine as expected. I've been facing this problem for a while. Has anyone else experie... |
videos are resizing themselves while scrolling |
|reactjs|react-native|video|react-native-video| |
I can run my flutter project witth Android Studio with "--dart-define-file-from=" config and it works. But when I try to run same project's android module( for debugging native code I open android folder with Android Studio) it doesn't see my config file. I know I have to clarify it like editting run/debug configuratio... |
How to Run Flutter Android Project Native Debug (android-> app module) with "--dart-define-file-from= config.json" config? |
|android|flutter|android-studio|flutter-run|dart-define| |
null |
all I have a project that will host Grafana app (whole app not only dashboard/snapshots) inside my website inside an iframe, I'm trying to set a SSO so my users wouldn't have to login to my site then into their Grafana account inside my website.
Grafana version and OS:
- Grafana 10.4.1 enterprise on windows 10
... |
Curiously, MySQL Workbench allows a Foreign Key Comment to be entered on the foreign key, but it does not generate it when synching to a database.
Entering a Foreign Key Comment in MySQL Workbench causes that table to keep showing up when synching as a change... very annoying! |
I have linked properly the `List-Adapter` and the other `list-item` components.
It didn't getting the `android:id` of `activity_main_cake_items.xml` and giving this error.
Cannot resolve symbol 'listviewCakes'
This is my files :
> **MainCakeItems.java**
```
package com.example.dessertshop;
import ... |
Listview - Getting error while linking the items correctly in Java |
|java|android|android-studio|android-listview|mobile-development| |
{"Voters":[{"Id":6752050,"DisplayName":"273K"},{"Id":8877,"DisplayName":"Ðаn"},{"Id":6870253,"DisplayName":"chtz"}],"SiteSpecificCloseReasonIds":[13]} |
I am using ionic 7 angular standalone but ion icons are not showing at all in web. i have also tried to add these scripts in index.html .
<script type="module" src="https://cdn.jsdelivr.net/npm/ionicons@latest/dist/ionicons/ionicons.esm.js"></script>
<script nomodule src="https://cdn.jsdelivr.net/npm/ionicons@latest... |
Ionic Angular Standalone ion-icon are not showing at all |
|angular|ionic-framework| |
I'm using the following IIS Rewrite Rule to block as many bots as possible.
<rule name="BotBlock" stopProcessing="true">
<match url=".*" />
<conditions>
<add input="{HTTP_USER_AGENT}" pattern="^$|bot|crawl|spider" />
</conditions>
<action type="CustomResponse" statusCode="403... |
Zion Bokobza's answer helped me but that `Main1Component.lastComp = this;` ought to be in the onInit not in the onDestroy, or else `lastComp` will remain null until the component is destroyed:
```
ngOnInit(): void {
if (!Main1Component.lastComp) {
this.name = 'Zion';
Main1Compone... |
You need to convert to a continuous scale to use minor ticks, since there are no minor breaks on a discrete axis:
``` r
dt %>%
ggplot(aes(var1, as.numeric(factor(ca)), fill = var2)) +
geom_col(width = 0.8, orientation = 'y') +
stat_summary(orientation = 'y', fun = sum, geom = "point", colour = "grey40",
... |
null |
null |
Trying to understand the `useCallback()` hook in react. In a blog post someone said that it solves the following problem:
> Before diving into useCallback() use, let's distinguish the problem useCallback() solves — the functions equality check.
>
>Functions in JavaScript are first-class citizens, meaning that a fu... |
useCallback hook and functions equality check problem |
|javascript|reactjs|react-hooks|hook|memoization| |
I have a procedure which sets the validation list for cells in a range. I finally got it to work, getting the correct range to be set as validation list.
But when I check the validation settings, the range is different. And I cannot understand what and why this happened.
Below is the messagebox telling me the range... |
There is no way that EF Core is bypassing your triggers. There must be a bug in the trigger logic.
Your trigger as it stands may or may not be correct, but it uses a huge amount of Bad Stuff:
* Cursors, instead of a joined update.
* You would need to join `inserted` and `deleted` using a full-join, although in thi... |
A typical trigger would look like this
```tsql
CREATE TRIGGER Change_TOMOGRAFIA ON YourTable
AFTER INSERT, UPDATE
AS
SET NOCOUNT ON;
IF TRIGGER_NESTLEVEL(@@PROCID) > 1
RETURN; -- prevent recursion
IF NOT UPDATE(no_stepdescription) OR NOT EXISTS (SELECT 1 FROM inserted)
RETURN; -- early bail-o... |
Actually, you can achieve the same result with some basic math :
```python
df.withColumn(
"rand",F.rand()*(F.col("max")-F.col("min"))+F.col("min")
)
```
The new columns will be in float but you can either trunc it or round it depending on your usecase. |
Hi as the title suggest I am trying to write/edit xml using xsd with xmlschema. I am using this xsd (https://github.com/NREL/bcl-gem/blob/develop/schemas/v3/measure_v3.xsd) and this xml file (https://drive.google.com/file/d/1WKJVBjn6IjmO-EZX9yGC8AaTCynUugFC/view?usp=sharing)
```
schema = xmlschema.XMLSchema(xsd_pat... |
I use shared preference in my project to store user information, but I encounter problems that the program encounters an error and does not load at all, and in terms of code, there is no problem with my code. But the application does not come up, How can I fix it?
This is the code of the class where I store the info... |
How I can use the shared preferences class in Java and Android studio? |
|java|android|kotlin|android-studio|android-developer-api| |
null |
If you're writing something that does "the same thing, with just one thing changing at each step", that's a loop, or if you foresee a situation that does warrant `if` statements, then you generally want to resolve them such that you handle "the largest thing first" (to ensure there's no fall-through) or by using `if-el... |
Shortly, here is the answer
[https://github.com/firebase/flutterfire/issues/4300#issuecomment-916883580][1]
I did a fork to the package, added it to my project's package folder, and made that condition always true. |
|astrojs| |
I have a `VGG19` trained with 224x224x3 images for binary classification using `flow_from_dataframe` and a `Places365` TensorFlow-version network that are combined to create a new model.
When I have to evaluate this new model I think I need an `ImageDataGenerator` with a `flow_from_dataframe` to access the images a... |
|yaml|config|blogs|astrojs|decap-cms| |
|javascript|astrojs| |
Based on the resolution of [issue 809][0], I resolved the issue with
pip install 'gdown>=5.1.0'
[0]: https://github.com/mlcommons/GaNDLF/pull/809 |
|astrojs| |
|javascript|pagespeed|astrojs|image-optimization| |
I'm trying to use the relu function on a matrix in MATLAB, and am calling it as `A = relu(A)`, but I keep getting the error
> Incorrect number or types of inputs or outputs for function relu.
I tried it on a scalar as well, and also get the same error. What could be causing this?
|
MATLAB relu "Incorrect number or types of inputs or outputs for function relu" |
|matlab| |
> I'm allowed to use both a stencil buffer and a depth buffer for the same render pass.
You can.
> How to differentiate between them.
They are different attachment points in the render pass, one called depth and one called stencil, so what problem are you having differentiating them?
Fragments must surviv... |
I am trying to migrate a webservice from WCF to WCF Core. I want to add the help menu, but I don't see that it is the same as the WCF one.
I want it to look like this
[enter image description here](https://i.stack.imgur.com/FbeIL.png)
But it looks like this now
[enter image description here](https://i.stack.img... |
Excel cell validation set by vba sets incorrect data range |
|excel|vba|validation|range| |
# Step 1: Create a Python 3 Virtual Environment
- Conda: Absent
```bash
virtualenv -p python3 <env name>
```
- Conda: Present and have sufficient disk space
```bash
conda create -n <env name> python==<version> -y
```
- Conda: Present and optimized disk space
```bash
conda create -prefix <./path/to/env_name... |
1. I'll provide you an instance [using UniRx][1].
```cs
using UniRx; //or R3
public class ExampleWithUniRx : MonoBehaviour
{
IDisposable stream = null;
public void Play(Text TextUI, string max, string min)
{
stream?.Dispose();
TimeSpan delay = TimeSpan.FromSeconds(3);
var ... |
write xml using xsd using xmlschema_from_json giving error: Reason: unable to select an element for decoding data, provide a valid 'path' argument |