5
Flamestro
199d

So I wrote some code to sort images in folders based on dates.
Like 2024>06>12.

I thought thats a good little script for GPT to help me out as I wanted to write it in rust.

Everything was fine and after processing all images and videos for 24 hours I was happy.

My test runs worked well.

Two days passed and I realize something.

Some images are not put in date folders. Why? Well I guess a little bug.

Starting to dive deep and checking if other images are in folders.

I see that I have images in folders since 2015 for most months and dates.

But why are some not put in exact day folders.

So another deep dive and I find out that the creation date is different to the folder the images are in.

Often its off by months.

Turns out I forgot to double check how the code generated by GPT maps the time between image creation date and unix epoch to a date folder.

It was just doing a division by an approximation of seconds that a month has, a year has, and a day has.

This caused things to be completely off the further away we go from 1970.

Lucky me that I did not mess up the creation dates :)

Looks like another 24 hours run

Comments
  • 2
    Layer 8 problem...
  • 2
    instead of how much help can AI make there should be a metric by how much fuckups
  • 2
    If you have AI write code for you, rather than simply expand existing patterns, assume every line of it is wrong. Actually, assume that no matter what it does. AI sucks.
  • 1
    @Root I agree, I was experimenting with it back then but stopped using it altogether now
Add Comment