Skip to content

Relecture#2

Open
guillaumefe wants to merge 8 commits into
MordicusEtCubitus:masterfrom
guillaumefe:master
Open

Relecture#2
guillaumefe wants to merge 8 commits into
MordicusEtCubitus:masterfrom
guillaumefe:master

Conversation

@guillaumefe

Copy link
Copy Markdown

Relecture du document python_profiling.ipynb

  • R1 : Correction de quelques coquilles
  • Traduction française partout où c'était possible
  • R2 : Mise au format (voir Reference File)
  • R3 : Cosmétique, tournures

branche de travaill : contribution-guillaume

  • virtualenv relecture
  • python3.5
  • jupyter-notebook : 6.0.0
  • Linux version 4.9.0-6-686-pae

@MordicusEtCubitus MordicusEtCubitus left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Merci pour les corrections de fautes que je valide, mais ton code change aussi les numéros des cellules ou les messages de sortie, ce que je ne souhaite pas. Peux-tu le revoir ?

{
"data": {
"text/plain": [
"24.584196265001083"

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Je ne souhaite pas modifier mes sorties

},
{
"cell_type": "code",
"execution_count": 4,

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Je ne souhaite pas modifier les numéros de cellules exécutées

Comment thread profiling/python_profiling.ipynb Outdated
]
}
],
"outputs": [],

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Je ne souhaite pas supprimer les sorties

Comment thread profiling/python_profiling.ipynb Outdated
"evalue": "name 'intersection' is not defined",
"output_type": "error",
"traceback": [
"\u001b[0;31m---------------------------------------------------------------------------\u001b[0m",

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Apparemment tu as eu cette erreur parce que tu as repris le notebook sans ré-exécuter les premières cellules
Je ne peux pas intégrer cette erreur

@MordicusEtCubitus MordicusEtCubitus left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Peux-tu corriger les éléments commentés afin que ce commit n'inclue vraiment que les fautes d'orthographe ?

Comment thread profiling/python_profiling.ipynb Outdated
{
"cell_type": "code",
"execution_count": 21,
"execution_count": 5,

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Je ne veux pas changer les numéros de cellules

Comment thread profiling/python_profiling.ipynb Outdated
"output_type": "stream",
"text": [
" 83650 function calls (4 primitive calls) in 0.011 seconds\n",
" 3 function calls in 0.000 seconds\n",

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Je ne souhaite pas modifier les sorties

Comment thread profiling/python_profiling.ipynb Outdated
"\u001b[0;31mNameError\u001b[0m Traceback (most recent call last)",
"\u001b[0;32m<ipython-input-5-04b57558cc95>\u001b[0m in \u001b[0;36m<module>\u001b[0;34m\u001b[0m\n\u001b[1;32m 1\u001b[0m \u001b[0;32mimport\u001b[0m \u001b[0mcProfile\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0;32m----> 2\u001b[0;31m \u001b[0mcProfile\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mrun\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m\"padovan(39)\"\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m",
"\u001b[0;32m/usr/lib/python3.5/cProfile.py\u001b[0m in \u001b[0;36mrun\u001b[0;34m(statement, filename, sort)\u001b[0m\n\u001b[1;32m 14\u001b[0m \u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 15\u001b[0m \u001b[0;32mdef\u001b[0m \u001b[0mrun\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mstatement\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mfilename\u001b[0m\u001b[0;34m=\u001b[0m\u001b[0;32mNone\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0msort\u001b[0m\u001b[0;34m=\u001b[0m\u001b[0;34m-\u001b[0m\u001b[0;36m1\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0;32m---> 16\u001b[0;31m \u001b[0;32mreturn\u001b[0m \u001b[0m_pyprofile\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0m_Utils\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mProfile\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mrun\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mstatement\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mfilename\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0msort\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m\u001b[1;32m 17\u001b[0m \u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 18\u001b[0m \u001b[0;32mdef\u001b[0m \u001b[0mrunctx\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mstatement\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mglobals\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mlocals\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mfilename\u001b[0m\u001b[0;34m=\u001b[0m\u001b[0;32mNone\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0msort\u001b[0m\u001b[0;34m=\u001b[0m\u001b[0;34m-\u001b[0m\u001b[0;36m1\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n",
"\u001b[0;32m/usr/lib/python3.5/profile.py\u001b[0m in \u001b[0;36mrun\u001b[0;34m(self, statement, filename, sort)\u001b[0m\n\u001b[1;32m 53\u001b[0m \u001b[0mprof\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0mself\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mprofiler\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 54\u001b[0m \u001b[0;32mtry\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0;32m---> 55\u001b[0;31m \u001b[0mprof\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mrun\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mstatement\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m\u001b[1;32m 56\u001b[0m \u001b[0;32mexcept\u001b[0m \u001b[0mSystemExit\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 57\u001b[0m \u001b[0;32mpass\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n",

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Idem, ici tu n'as pas exécuté les premières cellules, du coup le code ne passe pas

Comment thread profiling/python_profiling.ipynb Outdated
"On dénote en général 2 types de profileurs:\n",
"\n",
"* Les profileurs événementiels ou déterministes (tracing profiler), qui enregistrent toutes les actions qui se passent dans le programme et peuvent fournir beaucoup de statistiques très précises. \n",
"* Les profileurs événementiels ou déterministes (*Tracing Profiler*), qui enregistrent toutes les actions qui se passent dans le programme et peuvent fournir beaucoup de statistiques très précises. \n",

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ici, c'est ok
Sais-tu si je peux approver juste ce commit ? Je vais regarder dans la doc...

Comment thread profiling/python_profiling.ipynb Outdated
@@ -80,7 +80,7 @@
},
{
"cell_type": "code",
"execution_count": 1,
"execution_count": 7,

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Je ne souhaite pas changer les numéros de cellules

Comment thread profiling/python_profiling.ipynb Outdated
"metadata": {},
"outputs": [
{
"data": {
"text/plain": [
"66.20003481100139"
"68.96059255599903"

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Je ne souhaite pas changer les sorties

"output_type": "execute_result"
}
],
"outputs": [],

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pourquoi veux-tu supprimer le graphique ?

"source": [
"from graphviz import Digraph\n",
"\"\"\"\n",
"To install graphviz\n",

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

En fait je pensais laisser les commentaires en anglais, ainsi les non francophones peuvent quand-même comprendre le code à défaut des explications textuelles.

"metadata": {},
"source": [
"> Les boutons *Solution* empêchent le bon rendu de ce notebook par **github** ou *nbviewer*, vous pouvez utiliser ce lien **[MyBinder](https://mybinder.org/v2/gh/MordicusEtCubitus/CoursPython/master?filepath=profiling%2Fpython_profiling.ipynb)** pour une bonne visualisation."
"> Les boutons *Solution* empêchent le bon rendu de ce notebook par **github** ou *nbviewer*, vous êtes invités à utiliser ce lien **[MyBinder](https://mybinder.org/v2/gh/MordicusEtCubitus/CoursPython/master?filepath=profiling%2Fpython_profiling.ipynb)** pour bénéficier d'une meilleure visualisation."

@MordicusEtCubitus MordicusEtCubitus Aug 26, 2019

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok, pour changer la formulation, mais dans ce cas je préfère

Il est conseillé d'utiliser ce lien, car cela ne tient pas compte du genre masculin/féminin.
Dans ta formulation il faudrait écrire vous êtes invité(e)

"cell_type": "markdown",
"metadata": {},
"source": [
"## Types de profiler\n",

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

même Pofileurs

"metadata": {},
"outputs": [
{
"name": "stdout",

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Toujours les mêmes remarques sur les numéros de cellules et sorties

Comment thread profiling/python_profiling.ipynb Outdated
},
{
"cell_type": "code",
"execution_count": 20,

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Je ne comprends pas ce commit

@MordicusEtCubitus

Copy link
Copy Markdown
Owner

Merci beaucoup pour tes efforts et ta relecture
Si tu peux restituer les numéros de cellules, sorties et graphiques j'intègre le tout

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants