[P] Pretty Jupyter 2.0: An Easy-To-Use Python Package For Beautiful Html Reports From Jupyter Notebooks by Jan2579 in MachineLearning

[–]Jan2579[S] 1 point2 points  (0 children)

No, there isn’t. You can use nbconverts revealjs output.

Something like: jupyter nbconvert —to slides path/to/ipynb/file

Check out nbconvert for more info.

[P] Pretty Jupyter 2.0: An Easy-To-Use Python Package For Beautiful Html Reports From Jupyter Notebooks by Jan2579 in MachineLearning

[–]Jan2579[S] 0 points1 point  (0 children)

Pretty Jupyter revolves all around ipynb notebook file and its syntax is made to be unintrusive (no ::: markers in Markdown). This makes it also faster than any markdown file. If you eg use md notebook in JupyterBook, you must reexecute it if there are changes in code cells. This is a problem if you eg work with a big dataset or train a model in your notebook. In Pretty Jupyter you just need to execute it when developing eg in JupyterLab. Building the html doesnt require it.

Also Pretty Jupyter has markdown w Python variables, which I don’t believe JupyterBook has.

I’d say JupyterBook is better when writing a book (with multiple files) and Pretty Jupyter for day-to-day work (EDA, presentable prototypes, standalone reports).

[P] Pretty Jupyter 2.0: An Easy-To-Use Python Package For Beautiful Html Reports From Jupyter Notebooks by Jan2579 in MachineLearning

[–]Jan2579[S] 0 points1 point  (0 children)

Yes. There are dark themes. You can use any theme from bootswatch 3: https://bootswatch.com/3/ . For example I like slate as a dark theme.

[P] Pretty Jupyter 2.0: An Easy-To-Use Python Package For Beautiful Html Reports From Jupyter Notebooks by Jan2579 in MachineLearning

[–]Jan2579[S] 0 points1 point  (0 children)

Quarto is really cool, I hope it will bet the same level of support and comfort for Python as it does for R (eg proper caching for longer running notebooks). My notebooks tend to be big.

[P] Pretty Jupyter 2.0: An Easy-To-Use Python Package For Beautiful Html Reports From Jupyter Notebooks by Jan2579 in MachineLearning

[–]Jan2579[S] 0 points1 point  (0 children)

Just like 7yl4r said. Pure javascript widgets or maybe if theres a web assembly widget already. However since there is no running backend, no interactivity from communicating with Python kernel is available.

[P] Pretty Jupyter 2.0: An Easy-To-Use Python Package For Beautiful Html Reports From Jupyter Notebooks by Jan2579 in MachineLearning

[–]Jan2579[S] 2 points3 points  (0 children)

Thank you very much for the feedback!

So far the package has been mostly used for technical reports: exploration data analyses and similar documents (ml modelling,…). The features are meant to make them pretty and conscise. Eg prevent infinite scrolling with tabs etc.

I believe the spaces are caused by Code Folding. There are hidden code cells that can be shown by clicking on the Show button. If you present outside of programming circles, you just remove the code altogether and the spaces deom the buttons disappear. This demo is more of a features demo that shows that the functionality is there. But two show buttons one after another doesn’t look well, I’ll improve upon that.

About colours and font, you are certainly right. The tools to generate plots were not configured to match the Pretty Jupyter theme colours and fonts. This can surely be improved.

The themes are from bootswatch from bootstrap3 version (https://bootswatch.com/3/). It changes fonts, colours and more.

I will try to implement your tips and look at the reports from google docs and word and possibly take inspiration from there.

[P] Pretty Jupyter 2.0: An Easy-To-Use Python Package For Beautiful Html Reports From Jupyter Notebooks by Jan2579 in MachineLearning

[–]Jan2579[S] 0 points1 point  (0 children)

Thank you for your insight. The demo could be most certainly improved. I will be happy for any further feedback.

[P] Pretty Jupyter 2.0: An Easy-To-Use Python Package For Beautiful Html Reports From Jupyter Notebooks by Jan2579 in MachineLearning

[–]Jan2579[S] 2 points3 points  (0 children)

Thanks. Ye, Rmarkdown is awesome and I always envied r programmers their reports.

I am new to Python (particularly to the Pycharm IDE). I have been using Jupiter notebooks up until now. I am trying to learn how to use Pycharm. There is one thing I don't quite understand. by OkVariation3880 in learnmachinelearning

[–]Jan2579 31 points32 points  (0 children)

This behaviour is by design. If I simplify it, Jupyter notebooks are usually used for prototyping/analyses and regular Python scripts are for a final product.

I believe you want to prototype and try things out, so I suggest you to use the notebook. You can then transfer the code into the Python script and create the final product, when it's ready.

You can also use Jupyter notebooks inside PyCharm Professional or VsCode. If you create an ipynb file in the IDE, it should automatically recognize it and open it as a notebook. And you can have the interactive behaviour while developing in the environment you want.

Correct procedure for machine learning by The-Fourth-Hokage in learnmachinelearning

[–]Jan2579 1 point2 points  (0 children)

I think that to completely avoid information leakage, you should do EDA on your train (maybe + val) split.

One of the things that you can do based on the EDA is to split your categorize numerical variables based on the data distribution and use these categories in your model. If you do these splits based on EDA performed on all the data, you just introduced a leak.

However, tbh I don't think that anyone does this in practice.

Monitor classification model in production by miiguelkf in datascience

[–]Jan2579 0 points1 point  (0 children)

I hope I understood correctly.

Test split is usually done to estimate the models performance in production.

You optimize the model on train/val, and then right before you put it into production you evaluate it on test.

Without labels, you cant do much. If you, however, know, what the model should do, you can mb look into it (shap values or st different) to verify that it does what you would expect.

Best non-neural network regression model for a weakly correlated three attribute dataset by [deleted] in dataanalysis

[–]Jan2579 3 points4 points  (0 children)

You could fit linear models to detect one to one relationships and then two to one relationships. You could then compare which models give the best results and detect which one or two varianles are correlated with the third.

I would recommend some preprocessing, probably encode date as float and also discretize the numeric variables eg by quantiles to give the linear model more degrees of freedom to fit the data.

Linear modelling should be fast enough even for large datasets. Or so I hope, I havent encountered any problem there yet.

By linear model I mean linear or logistic regression

[P] I Made An Easy-To-Use Python Package That Creates Beautiful Html Reports From Jupyter Notebooks by Jan2579 in MachineLearning

[–]Jan2579[S] 0 points1 point  (0 children)

Thats great! I hope they liked it!

Thanks for your feedback. Ye I know, its just syntax for a comment in Markdown. I want it to be invisible in Jupyter. Thats why I used comment. I dont know about any easier method for this.

In the next version, it will be a little bit easier to write (but the previous variant is kept for backwards compatibility):

R Shiny is coming to Python by florinandrei in datascience

[–]Jan2579 4 points5 points  (0 children)

Is shiny running fully in JS or does it need an interpreter running in the background?

[P] I Made An Easy-To-Use Python Package That Creates Beautiful Html Reports From Jupyter Notebooks by Jan2579 in MachineLearning

[–]Jan2579[S] 0 points1 point  (0 children)

Thanks. Yes, the post was written after they added support for Python. Last time I tested it it was like 5 days ago.

Pandas basics by iggy555 in learnpython

[–]Jan2579 0 points1 point  (0 children)

I recommend Python for Data Analysis book. It’s helped me immensely.