guilgautier / DPPy

Python toolbox for sampling Determinantal Point Processes
https://dppy.readthedocs.io
MIT License
219 stars 52 forks source link

Git and notebooks #3

Closed rbardenet closed 6 years ago

rbardenet commented 6 years ago

I've had trouble with git and jupyter notebook in the past. Best to "restart and clear output" of each notebook before commiting. Otherwise, conflicts arise if different contributorshave differences in how they render images locally.

Naereen commented 6 years ago

I would agree, I even saw just this morning an extension that does just this job automatically (https://github.com/kynan/nbstripout). It can be installed easily and be activated as a git pre-hook (meaning it runs locally before you commit, so you don't even need to think about it!).

But I also agree about the opposite, if notebooks are included as examples and documentation, then having the output is definitely needed! See for instance this example in my SMPyBandits library.

rbardenet commented 6 years ago

I understand your point. Maybe the best trade-off is to also upload an html rendering (with figures) alongside the notebook itself (without figures). I agree this is not optimal, as it doesn't use the ability of github to automatically generate the rendering.

Naereen commented 6 years ago

I don't know about the best approach, that would be your choice, but I agree about the tradeoff!

guilgautier commented 6 years ago

Ok let's adopt the Kernel + Restart & Clear Output :)