WhereIsAI/github-issue-similarity huggingface dataset:
Issue 1:
Environment

Windows build number: 10.0.18362.0
Windows Terminal version (if applicable): 0.5.2681.0

Any other software? No

Steps to reproduce

Set the newTabProfile0 shortcut to "Ctrl+numpad_1" and save:

{
"command" : "newTabProfile0",
"keys" :
[
"ctrl+numpad_1"
]
},

Test the shortcut to verify that it works as expected (a new terminal tab opens as expected, regardless of which shell was currently active before).

Reopen settings; change this shortcut to "ctrl+shift+numpad_1" and save. Try to use shortcut.

Expected behavior

A new terminal tab to be opened with the appropriate profile:

Actual behavior

Depends on the currently active shell. If it's Powershell or cmd, nothing. If it's Bash WSL, ";5F" appears following the prompt:

(Found this issue while testing #2628; nto sure if it's also related to #2967 or if I'm just incorrectly stating the shortcut?)

Issue 2:
Is it possible to focus terminal by hotkey? E.g. when I click ctrl + ` it should open/focus terminal and put in in foreground.
Issue 1:
Elasticsearch version: 2.3.3

JVM version:1.8.0_101

OS version: Ubuntu 14.0.4

Description of the problem including expected versus actual behavior:

Steps to reproduce:

Adding documents with two different location formats:

PUT /foo
{
"mappings": {
"bar": {
"properties": {
"location": {
"type": "geo_point",
"lat_lon":true
}
}
}
}
}

PUT /foo/bar/1
{
"location": "42,72"
}

PUT /foo/bar/2
{
"location": {
"lat": 41,
"lon": 71
}
}

And searching wanting to output the sub-fields lat and lon which should be created as a result of setting "lat_lon": true in the mapping:

GET /foo/bar/_search
{
"fields": [ "location.lat", "location.lon" ]
}

returns

"hits": [
{
"_index": "foo",
"_type": "bar",
"_id": "2",
"_score": 1,
"fields": {
"location.lat": [
41
],
"location.lon": [
71
]
}
},
{
"_index": "foo",
"_type": "bar",
"_id": "1",
"_score": 1,
"fields": {
"location.lat": [
"42,72"
],
"location.lon": [
"42,72"
]
}
}

Where we see that in document 2 the fields are correct, but in document 1 both lat and lon fields are the full original string.

Have I misunderstood the documentation or is this a bug?

Setting lat_lon to true causes the latitude and longitude values to be indexed as numeric fields (called .lat and .lon).

Issue 2:
Hi,

I've recently upgraded ES from version 1.4.4 to 1.7.1 and now I have an issue with lat and lon indexed fields for geo_point.

In my index I have a field defined as follows:

"geolocation": {
"lat_lon": true,
"geohash_prefix": true,
"type": "geo_point",
"geohash": true
}

When issuing the query

{
"fields":["geolocation.lat","geolocation.lon","geolocation"],
"query": {
"filtered" : {
"query" : {
"match_all" : {}
},

"filter" : {
"geo_distance" : {
"distance" : "20km",
"geolocation" : {
"lat" : 37.9174,
"lon" : -122.3050
}
}
}
}
}
}

this is the response

"hits": {
"total": 3995,
"max_score": 1,
"hits": [
{
"_index": "idx",
"_type": "event",
"_id": "466201666890120",
"_score": 1,
"fields": {
"geolocation": [
"37.768991279975,-122.41938924477"
],
"geolocation.lon": [
"37.768991279975,-122.41938924477"
],
"geolocation.lat": [
"37.768991279975,-122.41938924477"
]
}
}

In other words geolocation.lat and geolocation.lon contain the pair and not just the single value.

Version 1.4.4 worked properly as expected.
Issue 1:
🐛 Bug

When indexing into a tensor with another tensor, around 10 times the size of the array is used in memory on the GPU.

To Reproduce

import torch

def torch_memory(device):
# Checks and prints GPU memory
print(f'{torch.cuda.memory_allocated(device)/1024/1024:.2f} MB USED')
print(f'{torch.cuda.memory_reserved(device)/1024/1024:.2f} MB RESERVED')
print(f'{torch.cuda.max_memory_allocated(device)/1024/1024:.2f} MB USED MAX')
print(f'{torch.cuda.max_memory_reserved(device)/1024/1024:.2f} MB RESERVED MAX')
print('')

device = torch.device(0)

a = torch.randn((1, 32, 24, 512, 512), dtype=torch.float32, device=device) # 768 MB tensor
torch_memory(device)

indices = a < 0 # 192 MB tensor
torch_memory(device)

a[indices] = 0. # Allocates 10 times of 768 MB
torch_memory(device)

This is the output that I get.

768.00 MB USED
768.00 MB RESERVED
768.00 MB USED MAX
768.00 MB RESERVED MAX

960.00 MB USED
960.00 MB RESERVED
960.00 MB USED MAX
960.00 MB RESERVED MAX

960.00 MB USED
8662.00 MB RESERVED
8643.00 MB USED MAX
8662.00 MB RESERVED MAX

The same thing happens when I use (supposed to be equivalent)

a.index_put_((indices,), torch.tensor([0.]).to(device))

and even when I just index into the array without assigning new values to it, a lot of memory is used.

a[indices]

Expected behavior

I'm not sure how much memory indexing/assignment like this is supposed to use, but surely not 10 times.

I tried this with CuPy arrays and they use 2-3 times the size of the array in memory.

Environment

PyTorch Version (e.g., 1.0): 1.1, 1.4, 1.5

OS (e.g., Linux): Linux

How you installed PyTorch (conda, pip, source): conda

Build command you used (if compiling from source): N/A

Python version: 3.7

CUDA/cuDNN version: 10.1, 7.6

GPU models and configuration: V100

Any other relevant information: N/A

Issue 2:
In [1]: x = torch.randn(20000, 20000,device='cuda')

In [2]: torch.cuda.max_memory_allocated()
Out[2]: 1600126976

In [3]: m = ~torch.eye(20000, dtype=torch.bool, device='cuda')

In [4]: torch.cuda.max_memory_allocated()
Out[4]: 2401239040

In [5]: x[m]
Out[5]:
tensor([ 0.6415, 0.2951, -0.7630, ..., 1.0940, 0.3103, 0.3631],
device='cuda:0')

In [6]: torch.cuda.max_memory_allocated()
Out[6]: 10001317888

In [7]: torch.__version__
Out[7]: '1.4.0a0+91c6d2e'

Titan XP

CUDA: 10.1

Why does it allocate about 4.75x of the indexed tensor, rather than just 1x?

cc @ngimel @VitalyFedyunin @mruberry
Issue 1:
Electron version: 1.6.2

Operating system: Windows 10

Actual behavior

When I'm maximizing the frameless window, the borders of window are out of screen.

For example: If I have my custom titlebar with 100px height and if I'll maximize the window, the titlebar will be 96px height.

On screenshot, the borders aren't out of screen.

How to reproduce

Please clone my repository by using these commands:

$ git clone https://github.com/nersent/wexond -b refactor

$ npm install

$ npm run browser

$ npm start

Or create your own frameless window, then maximize it and see what happens.

Issue 2:
Electron version: 1.4.15

Operating system: Windows 10

Actual behavior

Height is oversized by exactly 8px consistently (taskbar is set to small icons).

How to reproduce

https://github.com/adi518/electron-frameless-maximize-test
Issue 1:
Given the new this return type and F-bounded polymorphism I was a little surprised that I still could not express a functor interface

Example of Problem

interface IFunctor<A> {
/** Maps `A` into `B` */
map<B>(f: (a: A) => B): IFunctor<B>;
}

// A class with more than just IFunctor in it.
class Maybe<A> implements IFunctor<A> {
constructor(init: A) { this.value = init; }
isEmpty(): boolean { return false; }
map<B>(f: (a: A) => B): IFunctor<B> { return new Maybe(f(this.value)); }
}

function toString<F extends IFunctor<any>>(a: F) {
return a.map((v: any) => '' + v); // no way to define that this returns F<string>
}

let a: Maybe<number> = new Maybe(100);
let b: Maybe<string> = toString(a);
// error TS2322: Type 'IFunctor<string>' is not assignable to type 'Maybe<string>'.

Ideal Solution:

Ideally we should be able to define that F needs to have a generic type, which we can change

interface IFunctor<A, F<A> extends IFunctor<> {
/** Maps `A` into `B` */
map<B>(f: (a: A) => B): F<B>;
}

or we can define the functions generics

function toString<A, F<A> extends IFunctor<A>>(a: F<A>): F<string> { ... }

Issue 2:
It would be enormously helpful if this recognized type parameters:

abstract class Functor<a> {
abstract map<b>(map: (value: a) => b): this<b>;
}

abstract class Monad<a> extends Functor<a> {
abstract bind<b>(bind: (value: a) => this<b>): this<b>;
}
Issue 1:
System information (version)

OpenCV => :4.0beta:

Operating System / Platform => :Windows 10 64 bit:

Compiler => :Visual studio 2017:

Detailed description

Assertion failed when import caffe model, the message is as follws:

OpenCV: terminate handler is called! The last OpenCV error is:

OpenCV(4.0.0-beta) Error: Assertion failed (pbBlob.raw_data_type() == caffe::FLOAT16) in cv::dnn::dnn4_v20180917::`anonymous-namespace'::CaffeImporter::blobFromProto, file c:\build\master_winpack-build-win64-vc15\opencv\modules\dnn\src\caffe\caffe_importer.cpp, line 264

Steps to reproduce

const String model_desc = "../resnet18.prototxt";

const String model_binary = "../resnet18.caffemodel";

int test_caffe()

{

// init model
Net net = readNetFromCaffe(model_desc, model_binary);
if (net.empty())
{
printf("=> load net failed.\n");
return -1;
}

return 0;

}

int main()

{

//test_onnx();

test_caffe();

printf("=> Test done.\n");

system("pause");

return 0;

}

Issue 2:
System information (version)

OpenCV => ❔

Operating System / Platform => ❔

Compiler => ❔

Detailed description

Steps to reproduce
Issue 1:
reported: https://www.facebook.com/groups/free.code.camp.bengaluru/761870870602896/?ref=notif&notif_t=group_activity

Screen shot: https://scontent.fsnc1-1.fna.fbcdn.net/hphotos-xpf1/t31.0-8/11888635_963123300399960_4127102090052504172_o.jpg

Issue 2:
Challenge http://www.freecodecamp.com/challenges/bonfire-title-case-a-sentence has an issue. The Bonfire asks to "Return the provided string with the first letter of each word capitalized".The sentence should be worded differently because it should specify that all the letters remaining should be lower case. I realized this just at the moment of my submission looking at the tests.
Issue 1:
We should change this:

import { some-module } from 'some-lib'

To this:

from 'some-lib' import {some-module}

If we change to the second, the IDE can help us out by auto-completing the modules which we can import. In the first case we still can do it, but it's unnatural, we have to type everything and then come back.

Issue 2:
Consider the following import statement:

import { int, float } from '../lang';

With auto-suggest I need to start this by typing:

import {} from '../lang';

Then I can go back inside the {} and get auto-suggestions.

It would be very nice if TypeScript supported an alternate syntax for the same expression that was more conducive to auto-complete features.

For example:

import from '../lang' { int, float };

This doesn't introduce any confusion or ambiguity about the meaning of the expression, either to the transpiler or the human reader, yet it provides a time-saving experience to the author when taking advantage of auto-complete features. I can now simply type the expression naturally from left to right, and get auto-suggestions/completions for both the from '...' and {}.

There are other cases where an alternate syntax would be beneficial. I will update this issue as I compile a list. Hopefully others will comment with suggestions as well.
Issue 1:
Hello,

I upgrade my PHP version from PHP 5.6.36 to PHP 7.2, but I have a problem when I want to use the migrate function of Session component.

My simple line of code :

$this->request->getSession()->migrate(true, $newLifetime);

The error returned :

Warning: ini_set(): A session is active. You cannot change the session module's ini settings at this time

I have already a session opened before by my login page, but I want to change the session life time on login.

My Symfony version 2.8.44

Thanks for your help

Issue 2:
My entity :

/**

@Orm\Column(type="string",length="50")

@Assert\NotBlank()

@Assert\Choice(choices = {"spring", "summer","autumn","winter"})

*/

private $season;

My Form :

$builder->add('season', 'choice', array('choices' => array('spring'=>'season.spring','summer'=>'season.summer','autumn'=>'season.autumn','winter'=>'season.winter'),

'multiple' => true,

'expanded' => true

));

The validation is always false >> "The value you selected is not a valid choice"
Issue 1:
Challenge http://freecodecamp.com/challenges/bonfire-return-largest-numbers-in-arrays has an issue. Please describe how to reproduce it, and include links to screenshots if possible.

GO to http://freecodecamp.com/challenges/bonfire-return-largest-numbers-in-arrays

Check the unit test section. Script error being reported.

Not able to proceed with the test.

Issue 2:
Challenge http://freecodecamp.com/challenges/waypoint-write-reusable-javascript-with-functions has an issue. Please describe how to reproduce it, and include links to screenshots if possible.

The method of defining a function in the text differs from the method used in the code window. This may confuse campers.
Issue 1:
Challenge http://www.freecodecamp.com/challenges/waypoint-create-bootstrap-wells has an issue. Please describe how to reproduce it, and include links to screenshots if possible.

Please note that the classes described in the first checkpoint are mixed up. The

's with class "well" should go within the

's with class "col-xs-6", instead of the other way around. Thank you!

Repro steps:

Go to http://www.freecodecamp.com/challenges/waypoint-create-bootstrap-wells

and observe the first checkpoint on the left.

Issue 2:
Challenge http://www.freecodecamp.com/challenges/waypoint-create-bootstrap-wells has an issue. Please describe how to reproduce it, and include links to screenshots if possible.
Issue 1:
Describe the bug

I was using r112 and everything was ok, after upgrading to r120 I noticed a huge drop in fps when using composer render rather than the normal render.

there are 7 objects, 2000 instanced objects.

I know that 2000 sounds a big number, but it works well with normal rendering, and it was working well too in composer renders in r112!

Live example

https://jsfiddle.net/xuqws0Lg/

you can switch between composer render and normal render in the animate function to see the diff

Expected behavior

the expected behavior is that the composer renders in the same performance as normal render do.

Platform:

Device: Desktop

OS: Linux

Browser: Chrome

Three.js version: r120

Issue 2:
OutlinePass causes performance issue especially on mesh with a lot of faces.

I am not sure if this is bug or expected behavior. Thanks.

Screenshots

without outline (28ms)

with outline on mesh(ground) with small number of faces. (57ms)

with outline on mesh(tree) with a large number of faces. (170ms)

Platform:

Device: [Desktop]

OS: [MacOS]

Browser: [Chrome]

Three.js version: [r118]
Issue 1:
If I have abstract Foo and type Bar<:Foo ... end, type Baz<:Foo ... end, how should I denote a Vector accepting only any subtypes themselves (not instances) of Foo type?

This trick works:

typealias FooType{T<:Foo} Type{T}
v = Vector{FooType}
push!(v, Bar)
push!(v, Baz)
push!(v, Real) # throws an error as expected

But it would be nice to express that in-place, like Vector{Type{T<:Component}{T}} (not sure about concrete syntax, but you've got an idea)

Issue 2:
Currently, there is the following line in the sparse matmult code:

julia/base/sparse/linalg.jl

Lines 94 to 95
in
056b374

# For compatibility with dense multiplication API. Should be deleted when dense multiplication

# API is updated to follow BLAS API.

I am assuming that this means we want to have the more general A_mul_B*!(α,A,B,β,C) = αAB + βC methods which overwrite C (the BLAS gemm API) for dense arrays. Is that still the case? (It also seems possible to keep both APIs, i.e. keep the A_mul_B*!(C,A,B) methods, which would simply be defined as A_mul_B*!(C,A,B) = A_mul_B*!(1,A,B,0,C).)

I would personally like to have the gemm API defined for all array types (this has been expressed elsewhere). Implementing these methods for dense arrays seems fairly simple, since they would just directly call gemm et al. The sparse case is already implemented. The only real modification would be to the pure julia generic matmult, which does not accept α and β arguments.

This would lead to generic code that works with any type of array/number. I currently have a simple implementation of expm (after having done the modification to _generic_matmatmult!) which works with bigfloats and sparse arrays.
Issue 1:
It is not always does like this. But some of txt files fails. Plus, if i copy all types from NotePad and past it Atom it will be fixed.

after copy all from NotePad

Atom : 0.189.0 | 02.04.2015 00:44:55

Issue 2:
sometimes a chinese-char become '���',(as we all know that in charset utf-8, a chinese-char need 3 byte )
Issue 1:
The THREE.SVGLoader() is unable to process the attached SVG file. Since the file looks fine in Chrome Browser and other SVG editors, I assume the file conforms to the SVG standard. When the file is loaded to three.js, it does not crash anything, but it is rendered into gibberish.

Is the problem caused by a bug in the SVGLoader?

math.zip

Issue 2:
I mean, I understand SVGLoader is work in progress, but can you really get anywhere without this? my svg looks exploded :)

example:

<g transform="translate(226 226)">
<polygon fill="#F4F7FF" points="...

in SVGLoader there is only this:

case 'g':
style = parseStyle( node, style );
break;

while funcs like parseTransformNode are clearly there already
Issue 1:
System information (version)

Using the cv2 libraray in a python3.6 application, when I try to set the preferable target to CUDA using the line cv.dnn_Net.setPreferableTarget(cv.dnn.DNN_TARGET_CUDA) I get the following error;

TypeError: descriptor 'setPreferableTarget' requires a 'cv2.dnn_Net' object but received a 'int'

I followed the 4.2 docs when determing the object to use when setting the target.

Can't really determine if it's a bug or silly mistake.Everything else runs without issue.

Steps to reproduce

Issue 2:
This is a duplicate of #8658. Linking any application that uses the OpenCV C API without optimizations now results in a undefined reference to cvRound. This is because this function is now defined ONLY in a C++-only header: fast_math.hpp.

The reply (by "alalek") on that bug was that the C API shouldn't be used anymore. I don't know who alalek is; is this the official position? This issue effectively kills the C API. I.e. it's no longer an OPTION to use the C API without experiencing pain. And this particular issue isn't even hard to fix. I can give you a patch, and we can agree to at least not kill the C API on purpose, yes?
Issue 1:
Preflight Checklist

I have read the Contributing Guidelines for this project.

I agree to follow the Code of Conduct that this project adheres to.

I have searched the issue tracker for a feature request that matches the one I want to file, without success.

Electron Version

13.1.0

What operating system are you using?

Windows

Operating System Version

19042.985

What arch are you using?

x64

Last Known Working Electron version

No response

Expected Behavior

test.html should get loaded

Actual Behavior

electron crashes.

Testcase Gist URL

https://gist.github.com/t57ser/591ace911d2274f5500a702d178d7b96

Additional Information

After example.com gets loaded, open the devtools and type

location = "test://"

Issue 2:
Preflight Checklist

I have read the Contributing Guidelines for this project.

I agree to follow the Code of Conduct that this project adheres to.

I have searched the issue tracker for a feature request that matches the one I want to file, without success.

Electron Version

12.0.2

"electron-packager": "^15.2.0",

What operating system are you using?

Windows

Operating System Version

Windows 10 20H2

What arch are you using?

x64

Last Known Working Electron version

No response

Expected Behavior

Electron should not crash

Actual Behavior

Electron crashes when adding iframe

Testcase Gist URL

No response

app.zip

I've the following component wich crashes electron:

export class SimpleReportViewer extends HTMLElement {
constructor() {
super();
this.attachShadow({ mode: 'open' });
this.container = document.createElement('div');
this.shadowRoot.appendChild(this.container);
}
loadIframe() {
if (this.isConnected) {
this._iframe = document.createElement("iframe");
this._iframe.style.width = "100%";
this._iframe.style.height = "100%";
this._iframe.src = '/iframe.html';
this.container.appendChild(this._iframe);
}
}
connectedCallback() {
this.loadIframe();
}
}
customElements.define('simple-report-viewer', SimpleReportViewer);
Issue 1:
Create a new ContainerLayer type or an argument to a SceneBuilder.build() or SceneBuilder.pushScene() that allows the framework to explicitly raster cache the subtree right away so subsequent redraws of the scene are optimized.

Issue 2:
Use case

Although RepaintBoundary is a key widget in improving Flutter’s performance on the UI thread, it’s not well-utilized on the GPU thread. For example, only the lowest-level RepaintBoundary, which corresponds to leaf-level engine PictureLayer, currently triggers the raster cache on the GPU thread. In certain scenarios, raster caching can make a big performance difference -- e.g., 20%-30% in our home_scroll_perf average_frame_rasterizer_time_millis benchmark.

With the recent introduction of retained EngineLayers, we now have the opportunity to use RepaintBoundary to trigger more raster caching on the higher level RepaintBoundary. Similar to the recent opacity and PhysicalShapeLayer optimizations, we may be able to improve our performance by multiple times.

Proposal

Add a RasterCache option to the RepaintBoundary widget, so the developer can decide when to engage the optimizations. This option is not only to override our current raster cache heuristics, which are not very smart or reliable, but also allows developers to elect to make the tradeoff between quality and speed themselves. For example, when there’s a rotation transformation above the RepaintBoundary, raster caching the whole RepaintBoundary means that we’re no longer drawing pixel-perfect graphics, but the performance gain may significantly outweigh the quality drop (see #24627).

Things to implement:

Write performance tests for the scenarios where we’d like to see improvements. This will guide our implementation and check our correctness and performance.

Add a RasterCache option to the RepaintBoundary widget and wire it up between the framework and the engine.

Enable the engine-side raster caching based on the option.

Document the feature, and update Github issues to reflect the performance improvement, to teach our developers how to do it themselves.

Proposed by @liyuqian