WhereIsAI/github-issue-similarity huggingface dataset:
Issue 1:
This is a performance that goes 0..1, 0..1, 0..1, continually, with a particular period (duration) and curve.

Useful for things like continuous spinners.

See also #215.

Issue 2:
I'm working on an update to the CircularProgressIndicator to bring it in line with the Material Design spec (you can see the reasonably correct, although still not perfect Polymer implementation here: https://elements.polymer-project.org/elements/paper-spinner?view=demo:demo/index.html&active=paper-spinner)

This activity indicator will spin indefinitely until it's hidden or stopped.

While I haven't verified it, it appears in my current implementation there may be a 'paused frame' each time my performance is restarted. By 'paused frame', I mean something different from a dropped frame, but rather a frame where the animation just stops progressing for a frame – when the performance is started again.

So what I'd like, is the ability to specify a number of iterations (which could be infinite) for a Performance, so that I can expect the animation to be perfectly smooth between the end state of one iteration and the start state of the next.

@Hixie and I discussed this a bit and may be able to provide more context

Below is some sample code of what I'm currently doing (I can point you at the full code if that is helpful). Ideally I'd replace the 'Performance' with some new class... 'ContinuousPerformance'... or maybe I'd just use a Performance with a new argument 'iterations'? And I'd be able to remove my status listener that restarts the Performance.

Please let me know if you need any more detail.

_performance = new Performance(duration: new Duration(milliseconds: _kTotalDuration));

_strokeHeadProgress = new AnimatedValue<double>(0.0, end: 1.0,
curve: new Interval(0.0, 0.5, curve: Curves.fastOutSlowIn));

_strokeTailProgress = new AnimatedValue<double>(0.0, end: 1.0,
curve: new Interval(0.5, 1.0, curve: Curves.fastOutSlowIn));

_circleRotation = new AnimatedValue<double>(0.0, end: 0.85, curve: Curves.linear);

_stepIndex = 0;

_performance.addStatusListener((PerformanceStatus status) {
if (status == PerformanceStatus.completed) {
_stepIndex++;
if (_stepIndex >= 5) _stepIndex = 0;
_restartAnimation();
}
});
_performance.play();
Issue 1:
It seems "Request" object has no attribute "is_xhr" ，Getting warnings here... How do we fix this?

Issue 2:
This has been raised several times #3490 #3486 etc.

These have been closed due to no stacktrace or the issue being in a third party project.

Here are some reproducible examples just using Flask.

> python --version
Python 3.8.0
> pip install flask==0.12.4
Successfully installed Jinja2-2.11.1 MarkupSafe-1.1.1 Werkzeug-1.0.0 click-7.0 flask-0.12.4 itsdangerous-1.1.0

from flask import Flask, request
app = Flask(__name__)

@app.route('/')
def hello_world():
return "Is xhr" if request.is_xhr else "Isn't xhr"

Using the documented property is_xhr gives

File "/home/mitchell/.virtualenvs/flask/lib/python3.8/site-packages/werkzeug/local.py", line 347, in __getattr__
return getattr(self._get_current_object(), name)
AttributeError: 'Request' object has no attribute 'is_xhr'

Also in jsonify

from flask import Flask, jsonify
app = Flask(__name__)

@app.route('/')
def hello_world():
return jsonify({
"hello": "world",
})

gives

File "/home/mitchell/.virtualenvs/flask/lib/python3.8/site-packages/flask/json.py", line 298, in jsonify
if current_app.config['JSONIFY_PRETTYPRINT_REGULAR'] and not request.is_xhr:
File "/home/mitchell/.virtualenvs/flask/lib/python3.8/site-packages/werkzeug/local.py", line 347, in __getattr__
return getattr(self._get_current_object(), name)
AttributeError: 'Request' object has no attribute 'is_xhr'

Hopefully these purely-flask reproducible examples will help this get sorted out.
Issue 1:
When creating a daterange with a decimal number of minutes, pandas truncates everything before the decimal point. This leads to odd results e.g. if you're expecting to generate something every half minute and instead end up with something every 5 minutes, and even odder results if you have a float that is a whole number.

A less contrived example is if pandas is used to process the results of some API call where you don't know what unit you'll have to go to to get to a whole number. It would be safe, I guess, to convert everything to nanoseconds, but not especially readable.

A small, complete example of the issue

>>> import pandas as pd
>>> pd.date_range(end='2016-10-07T21:08:58.490180', periods=3, freq='0.5min')
DatetimeIndex(['2016-10-07 20:58:58.490180', '2016-10-07 21:03:58.490180',
'2016-10-07 21:08:58.490180'],
dtype='datetime64[ns]', freq='5T')
>>> pd.date_range(end='2016-10-07T21:08:58.490180', periods=3, freq='10080.0min')
DatetimeIndex([], dtype='datetime64[ns]', freq='0T')

Expected Output

For the first example:

DatetimeIndex(['2016-10-07 21:07:58.490180', '2016-10-07 21:08:28.490180', '2016-10-07 21:08:58.490180'], dtype='datetime64[ns]', freq='30S')

For the second:

DatetimeIndex(['2016-09-23 21:08:58.490180', '2016-09-30 21:08:58.490180', '2016-10-07 21:08:58.490180'], dtype='datetime64[ns]', freq='10080T')

Output of pd.show_versions()

## INSTALLED VERSIONS

commit: None

python: 2.7.6.final.0

python-bits: 64

OS: Linux

OS-release: 4.4.0-38-generic

machine: x86_64

processor: x86_64

byteorder: little

LC_ALL: None

LANG: en_US.UTF-8

pandas: 0.18.1

nose: 1.3.1

pip: 1.5.4

setuptools: 26.0.0

Cython: None

numpy: 1.11.1

scipy: 0.17.1

statsmodels: None

xarray: None

IPython: 5.1.0

sphinx: None

patsy: None

dateutil: 2.5.3

pytz: 2016.4

blosc: None

bottleneck: None

tables: None

numexpr: None

matplotlib: 1.3.1

openpyxl: None

xlrd: None

xlwt: None

xlsxwriter: None

lxml: None

bs4: None

html5lib: 0.999

httplib2: 0.9.2

apiclient: None

sqlalchemy: 1.0.15

pymysql: None

psycopg2: 2.6.2 (dt dec pq3 ext lo64)

jinja2: 2.8

boto: 2.41.0

pandas_datareader: None

Issue 2:
I'm new to pandas, so maybe I'm missing something, but I'd expected freq='.5s' to give me 500ms intervals, not 5s intervals:

pd.date_range(0, periods=5, freq='.5s')[1]

Timestamp('1970-01-01 00:00:05', offset='5S')

pd.date_range(0, periods=5, freq='500ms')[1]

Timestamp('1970-01-01 00:00:00.500000', offset='500L')

pd.version

'0.14.1'

import sys; sys.version

'3.4.1 (default, Jul 6 2014, 20:01:46) \n[GCC 4.9.0]'

Behaviour is the same under Python 2 and 3.
Issue 1:
I have been looking at the plethora of issues and attempts to fix sparse arrays and broadcast. For anyone not caught up on the general strife, here is a rough (although very incomplete) overview.

Current Problems:

#19561: broadcasting non numeric arrays causes problems because zero(::Type{Any}) doesn't exist

#19372: When should broadcast return dense vs sparse arrays?

Current Consensus:

Implement zero for strings

f(A) returns sparse if A is sparse, and f is zero preserving.

f(A,B) returns sparse if A and B are sparse, and f is zero preserving on either both or one of the zeros.

higher order cases get complicated quickly.

Proposed Solution:

Implement a new type of sparse array that can have a custom set default element.

For the first issue, this allows the simple solution of making the default element '' which will allow broadcasts to work sensibly.

For the second, we get the quite nice property that f(A,B...X) can be done by iterating over the nonzero values of all the various arrays, and then switching the default value to f(0,0...0). This will be simple to code, and will contain almost all of the advantages of the current approach.

Issue 2:
Is there any practical way to achieve this? Consider: I have a very large matrix describing edge weights between all pairs of vertices. This is an NxN matrix and is impractical for graphs with orders of 1e7 without using sparse matrices.

If I want the default edge weight of 1.0, I have to code specially around this to make a sparse matrix entry of "0" really be "1" (which is ok in this specific case because an edge weight of 0 is not defined). It would be much easier if I could specify "create this sparse matrix but any unspecified value should be X".

Is there already an easy way to do this that I've missed?
Issue 1:
Transferred from http://code.opencv.org/issues/2318

|| Dmitry Ponv on 2012-08-27 23:52
|| Priority: Low
|| Affected: None
|| Category: imgproc, video
|| Tracker: Feature
|| Difficulty: None
|| PR: None
|| Platform: None / None

Hough Circle detection to report the quality/accumulator count of each circle detected

Currently the Hough circle (and line) detection algorithms do not report the quality/accumulator value of each detected circle. This value "max_count" is thrown out after the function

if( max_count > acc_threshold )
{
float c[3];
c[0] = cx;
c[1] = cy;
c[2] = (float)r_best;
cvSeqPush( circles, c );
if( circles->total > circles_max )
return;
}

This makes the Hough circle detection almost completely useless, because it reports a number of circles and the programmer doesn't know which circles are more dominant than others. The only way for the programmer to know is to run the Hough circle detection repeatedly and decrease minimum accumulator level until a circle shows up.

This issue is also posted here
http://tech.groups.yahoo.com/group/OpenCV/message/88871

I may have already submitted this feature, but I'm not sure if it went through, I didn't find it in the list,

History

Kirill Kornyakov on 2012-09-24 12:06

Dmitry, thank you for the request, but please note:
# You shouldn't use High priority for things like this. We need more people asking for the same feature to say if it is important.
# You can propose your patch for the feature. It can be submitted as a pull request at the github.
- Priority changed from High to Low
- Category set to imgproc, video

Mikulas Krupicka on 2012-11-12 00:30

Indeed, the accumulator output would be useful (for both the Line and Circular Hough). Though it forced me to write my own implementation of Hough transform to get accumulator, it is unfurtunately quite slow.

Neo Carlitos on 2013-03-04 10:36

+1 It would be useful.

I believe the returned circles are ordered according to their accumulator value (?)

Issue 2:
Transferred from http://code.opencv.org/issues/1409

|| ivansorokin - on 2011-10-07 15:02
|| Priority: Normal
|| Affected: None
|| Category: imgproc, video
|| Tracker: Feature
|| Difficulty: None
|| PR: None
|| Platform: None / None

ability to get Hough accumulator value

Currently it is not possible to get Hough accumulator value (after stage 1 in icvHoughLinesStandard).

http://stackoverflow.com/questions/3265987/opencv-get-hough-accumulator-value

I also need this value. Currently I've just copy-paste this part of function from OpenCV, but I think it can be extracted in separate function.

History

Alexander Shishkov on 2012-02-12 20:26

- Description changed from Currently it is not possible to get Hough
accumulator value (after stage 1 in... to Currently it is not
possible to get Hough accumulator value (after stage 1 in... More
Issue 1:
Although Deno is "headless" that does not mean image/canvas processing would be useless. Why? Many of us use "image as data", for example zxy Tiles for map data (elevation is quite popular)

And often the results of the computations are exported by creating a canvas with the data and downloading it as an image.

I realize we have deno-canvas and skia_canvas

https://github.com/DjDeveloperr/deno-canvas

https://github.com/DjDeveloperr/skia_canvas

But they both have problems, see:

#18919

.. which is continues here: DjDeveloperr/deno-canvas#34

#19247

I should add that I used these to test 23 agent based models with deno, replacing a prior fragile Puppeteer solution (to run them in the browser). The runtime dropped drastically: from 3 minutes to 6 seconds (using 23 Deno workers)

So some really important "image as data" work is limping along with the current canvas/image libraries but having the browser and Deno have exactly the same API would be far better.

I propose Deno match the browser's canvas/image API, that is createCanvas and ImageBitmap.

Issue 2:
#1629 is about WebGL, it will likely take a lot of time to implement.

I think add OffscreenCanvas & CanvasRenderingContext2D interface at first is a good idea for now.

A lot of server-side image process like shields.io can be done in OffscreenCanvas with 2d renderer

(and it should be able to load image from disk / web / memory.)

Maybe render text will be a problem

Read from ttf directly? <- so we need a FontFace api with local file support

Use system font registry?
Issue 1:
Describe the bug

NB crashes when there is data in test data what was not used in train data

https://scikit-learn.org/stable/modules/generated/sklearn.naive_bayes.CategoricalNB.html#sklearn.naive_bayes.CategoricalNB

in real live test data values are different from train data

Issue 2:
Describe the bug

NB crashes when there is data in test data what was not used in train data

https://scikit-learn.org/stable/modules/generated/sklearn.naive_bayes.CategoricalNB.html#sklearn.naive_bayes.CategoricalNB

in real live test data values are different from train data
Issue 1:
When a user enters invalid data in an input field which has some restriction (for example, type="number") it prevents form from submitting (no event is fired) but there's no visual indication of what is wrong. Is it done on purpose or is it just a bug?

Issue 2:
Atom shell currently does not support HTML5 form validation notifications -- client side form validation is supported and you cannot submit invalid form entries, however, there is no visual cue or notification for invalid entries as there is in most browsers (see image below).

Is support for this planned?
Issue 1:
I am experiencing a race condition with a (Squid) proxy server, best described by @rdharrison2 in https://github.com/kennethreitz/requests/issues/2364#issuecomment-186214402:

In my case I'm making a large number of periodic https requests to a apache2 server with connection keep-alive timeout 5s. There is a race between the server closing a timed out persistent connection and the client making a request on the same connection. Given a bit of network latency the client can often attempt to send a request on the socket before it gets notified it as been closed.

Rather than implementing a retry logic, I would like to ensure that my requests Session keep-alive "timeout" is lower than that of proxy's. But I cannot seem to find out how.

Either I'm blind or it's just not supported?

Issue 2:
Request hooks are being merged with session hooks; since both hook dicts have a list as the value, one simply overwrites the other.
Issue 1:
Since there's a length property in each part of the union this is a legal property access but then we merge the doc descriptions without de-duping or differentiating which description is which (ie if each type had a length property of the same type but with a different description).

Issue 2:
I have an issue during writing a piece of declaration for existing node.js module - bluebird.js. The module has a method named props which gets an object has promises in it then return an object have same property names. It seems like object-version map. I wanted to add types for that.

For all I can easily get the types like

static all<T1, T2>(values: [Promise.Thenable<T1>, Promise.Thenable<T2>]): Promise<[T1, T2]>;
static all<T1, T2, T3>(values: [Promise.Thenable<T1>, Promise.Thenable<T2>, Promise.Thenable<T3>]): Promise<[T1, T2, T3]>;
// ...

But for props the other hand,

static props<T1>(object: {[k:string]: Promise.Thenable<T1>}): Promise<{[k:string]: T1}>;

I'm getting this

bluebird/bluebird-tests.ts(530,10): error TS2339: Property 'foo' does not exist on type '{ [k: string]: Foo; }'.
bluebird/bluebird-tests.ts(534,10): error TS2339: Property 'bar' does not exist on type '{ [k: string]: Bar; }'.

Is there any tip for issue like this?
Issue 1:
Description

At the moment it seems you can't trigger a dag with the CLI with the flag "replace_microseconds":

airflow/airflow/cli/commands/dag_command.py

Line 145
in
9337aa9

dag_id=args.dag_id, run_id=args.run_id, conf=args.conf, execution_date=args.exec_date

However, this argument seems to be available in the "trigger_dag" function:

airflow/airflow/api/common/trigger_dag.py

Line 103
in
9337aa9

def trigger_dag(

The proposal is to add this flag, e.g: airflow dags trigger --replace_microseconds=False ...

I'm willing to implement this, just wanted to check if this is a changed that is okay

Use case/motivation

No response

Related issues

No response

Are you willing to submit a PR?

Yes I am willing to submit a PR!

Code of Conduct

I agree to follow this project's Code of Conduct

Issue 2:
Description

airflow dags trigger CLI command always defaults with replace_microseconds=True because of the default value in the API. It would be very nice to be able to control this flag from the CLI.

Use case/motivation

We use AWS MWAA. The exposed interface is Airflow CLI (yes, we could also ask to get a different interface from AWS MWAA, but I think this is something that was just overlooked for the CLI?), which does not support overriding replace_microseconds parameter when calling airflow dags trigger CLI command.

For the most part, our dag runs for a given dag do not happen remotely at the same time. However, based on user behavior, they are sometimes triggered within the same second (albeit not microsecond). The first dag run is successfully triggered, but the second dag run fails the replace_microseconds parameter is wiping out the microseconds that we pass. Thus, DagRun.find_duplicates returns True for the second dag run that we're trying to trigger, and this raises the DagRunAlreadyExists exception.

Related issues

Not quite - they all seem to be around the experimental api and not directly related to the CLI.

Are you willing to submit a PR?

Yes I am willing to submit a PR!

Code of Conduct

I agree to follow this project's Code of Conduct
Issue 1:
The text editor is a little buggy. Every time I go to the next challenge I have to reset the code in order to get the text-editor to be responsive. Specific issues with the text editor include: inability to select a line of code, clicking on a line and having it select the line below, navigating with the arrow keys will often result in a hard return to the next line while half-way through.

I've had this issue on the last 20+ challenges. I've closed out my browser, closed tabs, refreshed the page and reset the code. None of these permanently solve the issue. I've talked with other coders and they are running into the same issue too.

Challenge Call out Optional Actions with Button Info has an issue.

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/57.0.2987.133 Safari/537.36.

Please describe how to reproduce this issue, and include links to screenshots if possible.

My code:

<link href="https://fonts.googleapis.com/css?family=Lobster" rel="stylesheet" type="text/css">
<style>
.red-text {
color: red;
}

h2 {
font-family: Lobster, Monospace;
}

p {
font-size: 16px;
font-family: Monospace;
}

.thick-green-border {
border-color: green;
border-width: 10px;
border-style: solid;
border-radius: 50%;
}

.smaller-image {
width: 100px;
}
</style>

<div class="container-fluid">
<h2 class="red-text text-center">CatPhotoApp</h2>

<p>Click here for <a href="#">cat photos</a>.</p>

<a href="#"><img class="smaller-image thick-green-border" src="https://bit.ly/fcc-relaxing-cat" alt="A cute orange cat lying on its back. "></a>

<img src="https://bit.ly/fcc-running-cats" class="img-responsive" alt="Three kittens running towards the camera. ">
<button class="btn btn-block btn-primary">Like</button>
<p>Things cats love:</p>
<ul>
<li>cat nip</li>
<li>laser pointers</li>
<li>lasagna</li>
</ul>
<p>Top 3 things cats hate:</p>
<ol>
<li>flea treatment</li>
<li>thunder</li>
<li>other cats</li>
</ol>
<form action="/submit-cat-photo">
<label><input type="radio" name="indoor-outdoor"> Indoor</label>
<label><input type="radio" name="indoor-outdoor"> Outdoor</label>
<label><input type="checkbox" name="personality"> Loving</label>
<label><input type="checkbox" name="personality"> Lazy</label>
<label><input type="checkbox" name="personality"> Crazy</label>
<input type="text" placeholder="cat photo URL" required>
<button type="submit">Submit</button>
</form>
</div>

Issue 2:
Challenge change-the-color-of-text has an issue.

User Agent is: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:47.0) Gecko/20100101 Firefox/47.0.

Please describe how to reproduce this issue, and include links to screenshots if possible.

<h2 style="color:red">CatPhotoApp</h2>

<p>Kitty ipsum dolor sit amet, shed everywhere shed everywhere stretching attack your ankles chase the red dot, hairball run catnip eat the grass sniff.</p>
Issue 1:
In the currently online pandas 0.19.2 documentation, I see the following inconsistency:

There is pandas.DataFrame.pivot_table, but also pandas.pivot_table.

In the same way, there is pandas.DataFrame.pivot and also pandas.pivot. (BTW., the latter has the dataframe argument missing.)

There is pandas.melt, but no pandas.DataFrame.melt.

The global versions of these methods (and probably others) are identical to the local ones except for an additional DataFrame argument, I think that all these should only be DataFrame methods. This would e.g. consistently enable chaining.

So let me suggest that the global versions should be removed, of course after a deprecation period.

Issue 2:
I think this is pretty duplicative and unless its a major bug fix should be avoided (in whatsnew), though I am +1 for API/enhancements...etc

need a 1-time cleanout of v0.13.0 txt...then (let's leave prior version alone)
Issue 1:
System information (version)

OpenCV => 4.5.3

Operating System / Platform => iOS 14.7.1 iOS 15

Compiler => Xcode 12

Detailed description

When I use version 4.5.3 to call the stitch method on IOS, the puzzle times an error. I can't debug. I don't know what the reason is. Please take a look. This problem is accidental. It is particularly easy to report an error by transmitting iPad screenshots to sitch.

The above figure shows the error stack.

code:

Ptr stitcher = Stitcher::create(cv::Stitcher::SCANS);

Stitcher::Status status = stitcher->stitch(imgs, pano);

Issue 2:
OpenCV => 3.4 / master (probably all 3.x versions)

Operating System / Platform => Windows 64 Bit

Compiler => python3.5, opencv3.4.3 (from pip here)

Detailed description

we should use XXX_create() functions, but folks will try to use XXX() instead ,

leading to cryptic errors:

>>> img = np.array((2,2),np.uint8) # a dummy img, just for demo purpose
>>> o = cv2.ORB() # this should not be possible, but it is !
>>> o # it is a valid instance
<ORB 0000000603D44F90>
>>> o.detect(img)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
TypeError: Incorrect type of self (must be 'Feature2D' or its derivative)
>>> type(o) # python thinks, everything is ok here ;(
<class 'cv2.ORB'>
>>> isinstance(o, cv2.Feature2D) # same delusion
True
>>>
>>> s = cv2.xfeatures2d.SIFT() # proper error.
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
AttributeError: module 'cv2.xfeatures2d' has no attribute 'SIFT'
>>> s = cv2.xfeatures2d_SIFT() # but uhhh !
>>> s.detect(img)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
TypeError: Incorrect type of self (must be 'Feature2D' or its derivative)
>>>
>>> c = cv2.CLAHE() # here, too !
>>> c.apply(img)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
TypeError: Incorrect type of self (must be 'CLAHE' or its derivative)